<<< Date Index >>>     <<< Thread Index >>>

Re: Problems changing folder to inbox with Courier 0.46



On Wed, 01 Sep 2004, TAKAHASHI Tamotsu wrote:

> On Tue, Aug 31, 2004 at 10:29:09AM -0400, Matt Larson wrote:
> > The issue is my Courier server doesn't like the period after INBOX.  I
> 
> Perhaps this patch might help you though I haven't tested this.

The patch below seems to work nicely for me, at least with the two
Courier IMAP servers I'm using.  Maybe, since Sam mentioned in the
Courier IMAP list that allowing any reference to "IMAP." is a mistake,
this might be incorporated in HEAD, maybe wrapped with an autoconf
"--enable-courier-workarounds"... Just a suggestion....

pete

> 
> -- 
> tamo

> --- imap/util.c~      Tue Aug 31 23:54:54 2004
> +++ imap/util.c       Wed Sep  1 00:02:43 2004
> @@ -284,6 +284,7 @@
>   * in IMAP.  Additionally, the filesystem converts multiple hierarchy
>   * delimiters into a single one, ie "///" is equal to "/".  IMAP servers
>   * are not required to do this.
> + * Moreover, IMAP servers may dislike the path ending with the delimiter.
>   */
>  char *imap_fix_path (IMAP_DATA *idata, char *mailbox, char *path, 
>      size_t plen)
> @@ -310,6 +311,8 @@
>      }
>      x++;
>    }
> +  if (path[x - 1] == idata->delim)
> +    x--;
>    path[x] = '\0';
>    return path;
>  }