Annotation of embedaddon/bird2/lib/alloca.h, revision 1.1

1.1     ! misho       1: /*
        !             2:  *     BIRD Library -- Alloca.h
        !             3:  *
        !             4:  *     (c) 2004 Ondrej Filip <feela@network.cz>
        !             5:  *
        !             6:  *     Can be freely distributed and used under the terms of the GNU GPL.
        !             7:  */
        !             8: 
        !             9: #ifndef _BIRD_ALLOCA_H_
        !            10: #define _BIRD_ALLOCA_H_
        !            11: 
        !            12: #ifdef HAVE_ALLOCA_H
        !            13: #include <alloca.h>
        !            14: #else
        !            15: #include <stdlib.h>
        !            16: #endif
        !            17: 
        !            18: #define allocz(len) ({ void *_x = alloca(len); memset(_x, 0, len); _x; })
        !            19: 
        !            20: #endif

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>