squatter

Ken Murchison ken at oceana.com
Sun Jun 15 22:37:34 EDT 2003


I just committed a similar patch.



Christian Schulte wrote:
> Vittorio Manfredini wrote:
> 
>> More information :
>>
>> squatter is not able to index mailboxes on virtual domain !!
>>
>>  
>>
>> they interpret the "." of the domain name as a separator and 
>> substitute it !!
>>
>> example :
>>
>> su cyrus
>> squatter -r -v user/vittorio at example.com
>> error opening user.vittorio at example^com: Mailbox does not exist
>>
>> May be a bug in 2.2 code ??
>>
>> vittorio
>>
>> -------------------------------------------------
>> This mail sent through IMP: http://horde.org/imp/
>>  
>>
> 
> This patch fixes the problem for me but I have no idea if it is correct!
> 
> ===================================================================
> RCS file: /cvs/src/cyrus/imap/squatter.c,v
> retrieving revision 1.5.4.11
> diff -u -r1.5.4.11 squatter.c
> --- squatter.c    20 May 2003 15:45:53 -0000    1.5.4.11
> +++ squatter.c    14 Jun 2003 22:26:37 -0000
> @@ -419,6 +419,7 @@
>     int rflag = 0;
>     int i;
>     char buf[MAX_MAILBOX_PATH+1];
> +    char newbuf[MAX_MAILBOX_PATH+1];
>     struct namespace squat_namespace;
>     int r;
> 
> @@ -479,11 +480,14 @@
>     for (i = optind; i < argc; i++) {
>         strlcpy(buf, argv[i], sizeof(buf));
>     /* Translate any separators in mailboxname */
> -    mboxname_hiersep_tointernal(&squat_namespace, buf, 0);
> -    index_me(buf, 0, 0, NULL);
> +    //mboxname_hiersep_tointernal(&squat_namespace, buf, 0);
> +    /* Handle conversion from the standard namespace to the internal 
> namespace */
> +        (*squat_namespace.mboxname_tointernal)(&squat_namespace, buf, 
> NULL, newbuf);
> +
> +    index_me(newbuf, 0, 0, NULL);
>     if (rflag) {
> -        strlcat(buf, ".*", sizeof(buf));
> -        (*squat_namespace.mboxlist_findall)(&squat_namespace, buf, 1,
> +        strlcat(newbuf, ".*", sizeof(newbuf));
> +        (*squat_namespace.mboxlist_findall)(&squat_namespace, newbuf, 1,
>                         0, 0, index_me, NULL);
>     }
>     }
> 
> 
> 
> 


-- 
Kenneth Murchison     Oceana Matrix Ltd.
Software Engineer     21 Princeton Place
716-662-8973 x26      Orchard Park, NY 14127
--PGP Public Key--    http://www.oceana.com/~ken/ksm.pgp





More information about the Info-cyrus mailing list