After an xfermailbox between 2 backends, I noticed the sieve scripts now contain e-mails.

I tracked this down to dump_mailbox() (mbdump.c):

  mbdir = opendir(sieve_path);
   [...]
        char tag_fname[2048];

        while((next = readdir(mbdir)) != NULL) {
                [...]
                /* create tagged name */
                if(sieve_isactive(sieve_path, next->d_name)) {
                    snprintf(tag_fname, sizeof(tag_fname),
                             "SIEVED-%s", next->d_name);
                } else {
                    snprintf(tag_fname, sizeof(tag_fname),
                             "SIEVE-%s", next->d_name);
                }
                        /* dump file */
                r = dump_file(0, !tag, pin, pout, filename, tag_fname);
                if (r) goto done;
            [...]

dump_file() gets passed 'filename' but that's not being set in the readdir loop. It's actually left over from the last message filename that was dumped.

Reply via email to