X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=common-src%2Falloca.c;fp=common-src%2Falloca.c;h=c6664b707ae21c228420028a272142be85b61039;hb=12179dea039515c06168c0037d048566a3f623de;hp=ad100874ccd49984b9257ed78eade8bc2a2553e9;hpb=94c03cae686e4196a345d72452fda2a5203768ce;p=debian%2Famanda diff --git a/common-src/alloca.c b/common-src/alloca.c index ad10087..c6664b7 100644 --- a/common-src/alloca.c +++ b/common-src/alloca.c @@ -21,9 +21,7 @@ allocating any. It is a good idea to use alloca(0) in your main control loop, etc. to force garbage collection. */ -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif +#include "amanda.h" #ifndef HAVE_ALLOCA @@ -131,7 +129,7 @@ find_stack_direction () alignment chunk size. The following default should work okay. */ #ifndef ALIGN_SIZE -#define ALIGN_SIZE sizeof(double) +#define ALIGN_SIZE SIZEOF(double) #endif typedef union hdr @@ -193,7 +191,7 @@ alloca (size) /* Allocate combined header + user data storage. */ { - register pointer new = malloc (sizeof (header) + size); + register pointer new = malloc (SIZEOF (header) + size); /* Address of header. */ ((header *) new)->h.next = last_alloca_header; @@ -203,7 +201,7 @@ alloca (size) /* User storage begins just after header. */ - return (pointer) ((char *) new + sizeof (header)); + return (pointer) ((char *) new + SIZEOF (header)); } }