diff options
author | Eric S. Raymond <esr@thyrsus.com> | 1998-10-20 04:33:28 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 1998-10-20 04:33:28 +0000 |
commit | 42eddaeaf36d467074f329599193030c3beba8ba (patch) | |
tree | 3f271d26a6eb861fefd0a384f3e11b8e965833aa /fetchmail.h | |
parent | 3299270c28441b9d01a24da727eeaa6553c4d7aa (diff) | |
download | fetchmail-42eddaeaf36d467074f329599193030c3beba8ba.tar.gz fetchmail-42eddaeaf36d467074f329599193030c3beba8ba.tar.bz2 fetchmail-42eddaeaf36d467074f329599193030c3beba8ba.zip |
Make alloca safe.
svn path=/trunk/; revision=2115
Diffstat (limited to 'fetchmail.h')
-rw-r--r-- | fetchmail.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/fetchmail.h b/fetchmail.h index 18de9f6c..f5fb1d41 100644 --- a/fetchmail.h +++ b/fetchmail.h @@ -397,6 +397,14 @@ int interface_approve(struct hostdata *); XMALLOCTYPE *xmalloc(int); XMALLOCTYPE *xrealloc(XMALLOCTYPE *, int); char *xstrdup(const char *); +#if defined(HAVE_ALLOCA_H) +#include <alloca.h> +#else +#ifdef _AIX + #pragma alloca +#endif +#endif +#define xalloca(ptr, t, n) if (!(ptr = (t) alloca(n))) error(PS_UNDEFINED, 0, "alloca failed") /* protocol driver and methods */ int do_protocol(struct query *, const struct method *); |