aboutsummaryrefslogtreecommitdiffstats
path: root/transact.c
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2005-07-31 00:42:44 +0000
committerMatthias Andree <matthias.andree@gmx.de>2005-07-31 00:42:44 +0000
commit92cadeb1565154cafec09b0fb3f036cee1b018a7 (patch)
treeb17a98bf3e2876c5a3cf03f7c855b48988fb7803 /transact.c
parent09f220e2fec10275e34f45731d625ef2f2d9755e (diff)
downloadfetchmail-92cadeb1565154cafec09b0fb3f036cee1b018a7.tar.gz
fetchmail-92cadeb1565154cafec09b0fb3f036cee1b018a7.tar.bz2
fetchmail-92cadeb1565154cafec09b0fb3f036cee1b018a7.zip
Kill alloca().
svn path=/trunk/; revision=4200
Diffstat (limited to 'transact.c')
-rw-r--r--transact.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/transact.c b/transact.c
index 0ca37d7e..0d40d1bf 100644
--- a/transact.c
+++ b/transact.c
@@ -1240,7 +1240,7 @@ int readheaders(int sock,
if (idp->val.status.mark == XMIT_RCPTBAD)
errlen += strlen(idp->id) + 2;
- xalloca(errmsg, char *, errlen+3);
+ errmsg = xmalloc(errlen + 3);
strcpy(errmsg, errhd);
for (idp = msgblk.recipients; idp; idp = idp->next)
if (idp->val.status.mark == XMIT_RCPTBAD)
@@ -1256,6 +1256,9 @@ int readheaders(int sock,
/* ship out the error line */
stuffline(ctl, errmsg);
+
+ if (errmsg != errhd)
+ free(errmsg);
}
/* issue the delimiter line */