summaryrefslogtreecommitdiff
path: root/src/spawn.c
diff options
context:
space:
mode:
authorJannis Hoffmann <jannis@fehcom.de>2024-07-18 14:55:05 +0200
committerJannis Hoffmann <jannis@fehcom.de>2024-07-18 14:55:05 +0200
commit25f74781424d5e13f0211c08cce8c2a1d60b9aec (patch)
tree92a1a19c59f8816dca604592d408184f48c3c4a3 /src/spawn.c
parentf1b71c9fe7dbb4886588a036399cf5ebe16b7c47 (diff)
update to 4.3.08
Diffstat (limited to 'src/spawn.c')
-rw-r--r--src/spawn.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/spawn.c b/src/spawn.c
index effcb26..f7f6f93 100644
--- a/src/spawn.c
+++ b/src/spawn.c
@@ -16,6 +16,9 @@
#include "auto_qmail.h"
#include "auto_uids.h"
#include "auto_spawn.h"
+#include "qmail.h"
+
+#define BUF_COMMANDS 1024
extern int truncreport;
extern int spawn();
@@ -64,7 +67,7 @@ ssize_t okwrite(int fd,char *buf,int n)
}
int flagreading = 1;
-char outbuf[1024];
+char outbuf[BUFSIZE_LINE];
buffer bo;
int stage = 0; /* reading 0:delnum 1:messid 2:sender 3:recip */
@@ -148,7 +151,7 @@ void docmd()
d[delnum].used = 1;
}
-char cmdbuf[1024];
+char cmdbuf[BUF_COMMANDS];
void getcmd()
{
@@ -188,7 +191,7 @@ void getcmd()
}
}
-char inbuf[128];
+char inbuf[BUFFER_SMALL];
int main(int argc,char **argv)
{
@@ -248,7 +251,7 @@ int main(int argc,char **argv)
if (d[i].used)
if (FD_ISSET(d[i].fdin,&rfds)) {
- r = read(d[i].fdin,inbuf,128);
+ r = read(d[i].fdin,inbuf,BUFFER_SMALL);
if (r == -1)
continue; /* read error on a readable pipe? be serious */
if (r == 0) {