diff options
| author | manuel <manuel@mausz.at> | 2013-02-04 02:34:11 +0100 |
|---|---|---|
| committer | manuel <manuel@mausz.at> | 2013-02-04 02:34:11 +0100 |
| commit | c8255e888cc262f39744cd452a69f9807ecc1cbf (patch) | |
| tree | 8e952a41a9fca9d97a3c43c347463b34ec5025a9 /qmail.c | |
| parent | 8514473287c9594137c6fbc39f5619672ebc2430 (diff) | |
| download | qmail-c8255e888cc262f39744cd452a69f9807ecc1cbf.tar.gz qmail-c8255e888cc262f39744cd452a69f9807ecc1cbf.tar.bz2 qmail-c8255e888cc262f39744cd452a69f9807ecc1cbf.zip | |
[PATCH] qmailqueue
Diffstat (limited to 'qmail.c')
| -rw-r--r-- | qmail.c | 13 |
1 files changed, 12 insertions, 1 deletions
| @@ -6,8 +6,17 @@ | |||
| 6 | #include "fd.h" | 6 | #include "fd.h" |
| 7 | #include "qmail.h" | 7 | #include "qmail.h" |
| 8 | #include "auto_qmail.h" | 8 | #include "auto_qmail.h" |
| 9 | #include "env.h" | ||
| 9 | 10 | ||
| 10 | static char *binqqargs[2] = { "bin/qmail-queue", 0 } ; | 11 | static char *binqqargs[2] = { 0, 0 } ; |
| 12 | |||
| 13 | static void setup_qqargs() | ||
| 14 | { | ||
| 15 | if(!binqqargs[0]) | ||
| 16 | binqqargs[0] = env_get("QMAILQUEUE"); | ||
| 17 | if(!binqqargs[0]) | ||
| 18 | binqqargs[0] = "bin/qmail-queue"; | ||
| 19 | } | ||
| 11 | 20 | ||
| 12 | int qmail_open(qq) | 21 | int qmail_open(qq) |
| 13 | struct qmail *qq; | 22 | struct qmail *qq; |
| @@ -15,6 +24,8 @@ struct qmail *qq; | |||
| 15 | int pim[2]; | 24 | int pim[2]; |
| 16 | int pie[2]; | 25 | int pie[2]; |
| 17 | 26 | ||
| 27 | setup_qqargs(); | ||
| 28 | |||
| 18 | if (pipe(pim) == -1) return -1; | 29 | if (pipe(pim) == -1) return -1; |
| 19 | if (pipe(pie) == -1) { close(pim[0]); close(pim[1]); return -1; } | 30 | if (pipe(pie) == -1) { close(pim[0]); close(pim[1]); return -1; } |
| 20 | 31 | ||
