From: Russell Bryant Date: Tue, 27 May 2008 19:27:48 +0000 (+0000) Subject: Add printf format attribute for vasprintf(). X-Git-Tag: 1.6.2.0-beta1~2145 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ed1976a1ccf09052f0e72f31a759648386f8a78a;p=thirdparty%2Fasterisk.git Add printf format attribute for vasprintf(). (closes issue #12729) Reported by: snuffy Patches: bug_12729.diff uploaded by snuffy (license 35) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@118556 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/include/asterisk/compat.h b/include/asterisk/compat.h index 4ba4c46d4b..950712060b 100644 --- a/include/asterisk/compat.h +++ b/include/asterisk/compat.h @@ -110,7 +110,7 @@ int unsetenv(const char *name); #endif #if !defined(HAVE_VASPRINTF) && !defined(__AST_DEBUG_MALLOC) -int vasprintf(char **strp, const char *fmt, va_list ap); +int __attribute__ ((format (printf, 2, 0))) vasprintf(char **strp, const char *fmt, va_list ap); #endif #ifndef HAVE_STRLCAT