Author: metze Date: 2006-01-10 07:08:27 +0000 (Tue, 10 Jan 2006) New Revision: 12814
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=12814 Log: we need this here too, as we'll include replace.h for building heimdal/* too, and for this we don't include includes.h (hopefully) fix the build on AIX metze Modified: branches/SAMBA_4_0/source/lib/replace/replace.h Changeset: Modified: branches/SAMBA_4_0/source/lib/replace/replace.h =================================================================== --- branches/SAMBA_4_0/source/lib/replace/replace.h 2006-01-10 03:45:15 UTC (rev 12813) +++ branches/SAMBA_4_0/source/lib/replace/replace.h 2006-01-10 07:08:27 UTC (rev 12814) @@ -100,6 +100,18 @@ #define bzero(a,b) memset((a),'\0',(b)) #endif +#ifndef PRINTF_ATTRIBUTE +#if !defined(NO_PRINTF_ATTRIBUTE) && (__GNUC__ >= 3) +/** Use gcc attribute to check printf fns. a1 is the 1-based index of + * the parameter containing the format, and a2 the index of the first + * argument. Note that some gcc 2.x versions don't handle this + * properly **/ +#define PRINTF_ATTRIBUTE(a1, a2) __attribute__ ((format (__printf__, a1, a2))) +#else +#define PRINTF_ATTRIBUTE(a1, a2) +#endif +#endif + /* add varargs prototypes with printf checking */ #ifndef HAVE_SNPRINTF_DECL int snprintf(char *,size_t ,const char *, ...) PRINTF_ATTRIBUTE(3,4);
