From e61e36e56a2c1a797c146c94d04678a2558dca94 Mon Sep 17 00:00:00 2001 From: Brendan Cully Date: Sat, 10 Jan 2009 21:44:41 -0800 Subject: [PATCH] Use known connection delimiter in imap_expand_path --- ChangeLog | 9 ++++++++- imap/util.c | 4 +++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index cb8fcd21..d86c9571 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,11 @@ -2009-01-10 17:47 -0800 Brendan Cully (d6ee34f3ccaf) +2009-01-10 21:43 -0800 Brendan Cully (aa069968e4d5) + + * imap/util.c: Guard against NULL pointers in imap_mxcmp + + * imap/imap_private.h, imap/util.c: Canonicalize IMAP mailboxes before + comparing them. + + * imap/util.c: Fix last commit * imap/util.c: Prioritize the entered IMAP folder delimiter. First priority is the connection delimiter. Second priority is the user's diff --git a/imap/util.c b/imap/util.c index 5aff9bdc..62f77a16 100644 --- a/imap/util.c +++ b/imap/util.c @@ -54,6 +54,7 @@ int imap_expand_path (char* path, size_t len) { IMAP_MBOX mx; + IMAP_DATA* idata; ciss_url_t url; char fixedpath[LONG_STRING]; int rc; @@ -61,8 +62,9 @@ int imap_expand_path (char* path, size_t len) if (imap_parse_path (path, &mx) < 0) return -1; + idata = imap_conn_find (&mx.account, M_IMAP_CONN_NONEW); mutt_account_tourl (&mx.account, &url); - imap_fix_path(NULL, mx.mbox, fixedpath, sizeof (fixedpath)); + imap_fix_path (idata, mx.mbox, fixedpath, sizeof (fixedpath)); url.path = fixedpath; rc = url_ciss_tostring (&url, path, len, U_DECODE_PASSWD); -- 2.40.0