[EMAIL PROTECTED] writes:

--On Samstag, 30. August 2003 16:37 -0400 Sam Varshavchik
<[EMAIL PROTECTED]> wrote:

+// PATCH: check/fix Maildir
+int _MaildirCheckFix(const char *dir, int autocreate)
+{
+struct stat stat_buf;
+
+       // check if directory exists
+       if (! stat(dir, &stat_buf) )        return( S_ISDIR(stat_buf.st_mode) );
+       if (! autocreate)               return(0);      // legacy fallback
+       fprintf(stderr, "DEBUG maildrop: mkdir %s\n", dir);
+       if (! mkdir(dir, 0700) )        return(1);      // success
+       merr << "maildrop: mkdir " << dir << ": " << strerror(errno) << "\n";

This is not going to create a maildir.

Works for me ;)

The snipped above only creates one of the four directories which
make up a maildir, if it does not exist already.

And you need all four of them.


Even if it did, it is not going to create a proper maildir folder (quota
support would be broken).

Quota support just continues to work as it always worked. Maildrop will create the file maildirsize if MAILDIRQUOTA is available in the environment, which is usually set by the auth backend. No need to mess around with this file.

It's not going to work if you attempt to deliver directly to this folder. Because the maildirfolder file is absent, the quota file in the main maildir will not be updated.


Attachment: pgp00000.pgp
Description: PGP signature

Reply via email to