diff options
author | Jannis Hoffmann <jannis@fehcom.de> | 2024-07-18 15:15:18 +0200 |
---|---|---|
committer | Jannis Hoffmann <jannis@fehcom.de> | 2024-07-18 15:15:18 +0200 |
commit | 7b4d3ab22988d021d5f12b81aec746f7e486fa52 (patch) | |
tree | 651e78e316411a39baadadb1cfaca450e1351c7f /src/qmail-tcpok.c | |
parent | 25f74781424d5e13f0211c08cce8c2a1d60b9aec (diff) |
update to 4.3.09
Diffstat (limited to 'src/qmail-tcpok.c')
-rw-r--r-- | src/qmail-tcpok.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/src/qmail-tcpok.c b/src/qmail-tcpok.c index 9447844..0e79591 100644 --- a/src/qmail-tcpok.c +++ b/src/qmail-tcpok.c @@ -1,9 +1,9 @@ +#include <unistd.h> #include "logmsg.h" #include "buffer.h" #include "lock.h" #include "open.h" -#include <unistd.h> -#include "auto_qmail.h" +#include "auto_queue.h" #include "exit.h" #include "qmail.h" @@ -17,21 +17,23 @@ int main() int fd; int i; - if (chdir(auto_qmail) == -1) - logmsg(WHO,111,FATAL,B("unable to chdir to: ",auto_qmail)); - if (chdir("queue/lock") == -1) - logmsg(WHO,111,FATAL,B("unable to chdir to ",auto_qmail,"/queue/lock: ")); + if (chdir(auto_queue) == -1) + logmsg(WHO,111,FATAL,B("unable to chdir to: ",auto_queue)); + if (chdir("queue") == -1) + logmsg(WHO,111,FATAL,B("unable to chdir to: ",auto_queue,"/queue")); + if (chdir("lock") == -1) + logmsg(WHO,111,FATAL,B("unable to chdir to ",auto_queue,"/queue/lock")); fd = open_write("tcpto"); if (fd == -1) - logmsg(WHO,111,FATAL,B("unable to write ",auto_qmail,"/queue/lock/tcpto: ")); + logmsg(WHO,111,FATAL,B("unable to write ",auto_queue,"/queue/lock/tcpto")); if (lock_ex(fd) == -1) - logmsg(WHO,111,FATAL,B("unable to lock ",auto_qmail,"/queue/lock/tcpto: ")); + logmsg(WHO,111,FATAL,B("unable to lock ",auto_queue,"/queue/lock/tcpto")); buffer_init(&bo,write,fd,buf,sizeof(buf)); for (i = 0; i < sizeof(buf); ++i) buffer_put(&bo,"",1); if (buffer_flush(&bo) == -1) - logmsg(WHO,111,FATAL,B("unable to clear ",auto_qmail,"/queue/lock/tcpto: ")); + logmsg(WHO,111,FATAL,B("unable to clear ",auto_queue,"/queue/lock/tcpto")); _exit(0); } |