summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCHTEKK <CHTEKK@localhost>2007-04-21 23:24:38 +0000
committerCHTEKK <CHTEKK@localhost>2007-04-21 23:24:38 +0000
commit96e8111a4ba20f375b92ee3c0d7ae611b0096232 (patch)
tree5b04ab6274f4b072d6caab2abcc03cae77b43667
parentNot all of them ... (diff)
downloadchtekk-96e8111a4ba20f375b92ee3c0d7ae611b0096232.tar.gz
chtekk-96e8111a4ba20f375b92ee3c0d7ae611b0096232.tar.bz2
chtekk-96e8111a4ba20f375b92ee3c0d7ae611b0096232.zip
Last cleanups.
svn path=/; revision=39
-rw-r--r--vda/postfix-2.4.0-vda-ng.patch20
1 files changed, 12 insertions, 8 deletions
diff --git a/vda/postfix-2.4.0-vda-ng.patch b/vda/postfix-2.4.0-vda-ng.patch
index be8591d..af58bca 100644
--- a/vda/postfix-2.4.0-vda-ng.patch
+++ b/vda/postfix-2.4.0-vda-ng.patch
@@ -179,7 +179,7 @@ diff -Nru postfix-2.4.0/src/util/file_limit.c postfix-2.4.0-vda/src/util/file_li
#ifdef SIGXFSZ
diff -Nru postfix-2.4.0/src/virtual/mailbox.c postfix-2.4.0-vda/src/virtual/mailbox.c
--- postfix-2.4.0/src/virtual/mailbox.c 2006-06-26 14:59:19.000000000 +0200
-+++ postfix-2.4.0-vda/src/virtual/mailbox.c 2007-04-19 10:57:41.000000000 +0200
++++ postfix-2.4.0-vda/src/virtual/mailbox.c 2007-04-22 01:17:21.000000000 +0200
@@ -70,6 +70,58 @@
#define YES 1
#define NO 0
@@ -199,7 +199,7 @@ diff -Nru postfix-2.4.0/src/virtual/mailbox.c postfix-2.4.0-vda/src/virtual/mail
+ * if it is and the virtual mailbox limit can't be overridden, fall back to virtual_mailbox_limit and
+ * warn the user, else use the value directly as the mailbox limit.
+ */
-+ if ((limit_res = mail_addr_find(virtual_mailbox_limit_maps, state.msg_attr.user, (char **) NULL))) {
++ if (*var_virt_mailbox_limit_maps != 0 && (limit_res = mail_addr_find(virtual_mailbox_limit_maps, state.msg_attr.user, (char **) NULL)) != 0) {
+ n = atol(limit_res);
+ if (n > 0) {
+ if ((n < var_message_limit) && (!var_virt_mailbox_limit_override)) {
@@ -239,7 +239,7 @@ diff -Nru postfix-2.4.0/src/virtual/mailbox.c postfix-2.4.0-vda/src/virtual/mail
/* deliver_mailbox_file - deliver to recipient mailbox */
static int deliver_mailbox_file(LOCAL_STATE state, USER_ATTR usr_attr)
-@@ -207,52 +259,54 @@
+@@ -207,62 +259,72 @@
* Look up the mailbox owner rights. Defer in case of trouble.
*/
uid_res = mail_addr_find(virtual_uid_maps, state.msg_attr.user,
@@ -325,12 +325,16 @@ diff -Nru postfix-2.4.0/src/virtual/mailbox.c postfix-2.4.0-vda/src/virtual/mail
/*
* Deliver to mailbox or to maildir.
-@@ -261,8 +315,15 @@
+ */
+ #define LAST_CHAR(s) (s[strlen(s) - 1])
- if (LAST_CHAR(usr_attr.mailbox) == '/')
- *statusp = deliver_maildir(state, usr_attr);
+- if (LAST_CHAR(usr_attr.mailbox) == '/')
+- *statusp = deliver_maildir(state, usr_attr);
- else
- *statusp = deliver_mailbox_file(state, usr_attr);
++ if (LAST_CHAR(usr_attr.mailbox) == '/') {
++ *statusp = deliver_maildir(state, usr_attr);
++ }
+ else {
+ int changed_limit;
+
@@ -345,7 +349,7 @@ diff -Nru postfix-2.4.0/src/virtual/mailbox.c postfix-2.4.0-vda/src/virtual/mail
* Cleanup.
diff -Nru postfix-2.4.0/src/virtual/maildir.c postfix-2.4.0-vda/src/virtual/maildir.c
--- postfix-2.4.0/src/virtual/maildir.c 2006-06-26 14:59:19.000000000 +0200
-+++ postfix-2.4.0-vda/src/virtual/maildir.c 2007-04-22 00:49:11.000000000 +0200
++++ postfix-2.4.0-vda/src/virtual/maildir.c 2007-04-22 01:24:16.000000000 +0200
@@ -63,28 +63,382 @@
#include <mbox_open.h>
#include <dsn_util.h>
@@ -1103,7 +1107,7 @@ diff -Nru postfix-2.4.0/src/virtual/maildir.c postfix-2.4.0-vda/src/virtual/mail
+ if (mail_copy_status == 0) {
+ if (sane_link(tmpfile, newfile) < 0
+ && (errno != ENOENT
-+ || (make_dirs(curdir, 0700), make_dirs(newdir, 0700), make_dirs(tmpdir,0700)) < 0
++ || (make_dirs(curdir, 0700), make_dirs(newdir, 0700), make_dirs(tmpdir, 0700)) < 0
+ || sane_link(tmpfile, newfile) < 0)) {
+ dsb_simple(why, mbox_dsn(errno, "4.2.0"), "create maildir file %s: %m", newfile);
+ mail_copy_status = MAIL_COPY_STAT_WRITE;