*** qmail.c.orig Sat Sep 5 11:33:37 1998 --- qmail.c Thu May 23 09:38:51 2002 *************** *** 6,19 **** #include "fd.h" #include "qmail.h" #include "auto_qmail.h" ! static char *binqqargs[2] = { "bin/qmail-queue", 0 } ; int qmail_open(qq) struct qmail *qq; { int pim[2]; int pie[2]; if (pipe(pim) == -1) return -1; if (pipe(pie) == -1) { close(pim[0]); close(pim[1]); return -1; } --- 6,30 ---- #include "fd.h" #include "qmail.h" #include "auto_qmail.h" + #include "env.h" ! static char *binqqargs[2] = { 0, 0 } ; ! ! static void setup_qqargs() ! { ! if(!binqqargs[0]) ! binqqargs[0] = env_get("QMAILQUEUE"); ! if(!binqqargs[0]) ! binqqargs[0] = "bin/qmail-queue"; ! } int qmail_open(qq) struct qmail *qq; { int pim[2]; int pie[2]; + + setup_qqargs(); if (pipe(pim) == -1) return -1; if (pipe(pie) == -1) { close(pim[0]); close(pim[1]); return -1; }