3 * \brief Header: definitions for alloca for popt
5 * Definitions for alloca (mostly extracted from AC_FUNC_ALLOCA). According
6 * to the autoconf manual in dome versions of AIX the declaration of alloca
7 * has to precede everything else execept comments and prepocessor directives,
8 * i.e. including this file has to preceed anything else.
10 * NOTE: alloca is redefined as malloc on systems which fail to support alloca.
11 * Don't include this header if you frequently use alloca in order to avoid an
12 * unlimited amount of memory leaks.
13 * popt uses alloca only during program startup, i.e. the memory leaks caused
14 * by this redefinition are limited.
17 #ifndef MC_POPTALLOCA_H
18 #define MC_POPTALLOCA_H
20 /* AIX requires this to be the first thing in the file. */
22 # define alloca __builtin_alloca
26 # define alloca _alloca
34 # ifndef alloca /* predefined by HP cc +Olibcalls */
44 # if !defined(STDC_HEADERS) && defined(HAVE_MALLOC_H)
47 # define alloca malloc