[PATCH] warning: implicit declaration of function ‘asprintf’
Ricardo Maraschini
ricardo.maraschini at opservices.com.br
Mon Jun 25 19:27:43 CEST 2012
Hello,
Accordingly to feature_test_macros(7):
"NOTE: In order to be effective, a feature test macro must be defined before including any header files."
As we already define _GNU_SOURCE on config.h, pushing its include to be the first will suppress the boring "implicit declaration of function ‘asprintf’" warning message during compilation.
OK? Comments?
--- common/macros.c (revision 1973)
+++ common/macros.c (working copy)
@@ -22,8 +22,8 @@
*
*****************************************************************************/
+#include "../include/config.h"
#include "../include/macros.h"
-#include "../include/config.h"
#include "../include/common.h"
#include "../include/objects.h"
#include "../include/statusdata.h"
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Nagios-devel mailing list
Nagios-devel at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-devel
More information about the Developers
mailing list