summaryrefslogtreecommitdiffstats
path: root/pceplib/pcep_msg_objects.c
diff options
context:
space:
mode:
authorDavid Lamparter <equinox@opensourcerouting.org>2021-04-23 12:04:58 +0200
committerDavid Lamparter <equinox@opensourcerouting.org>2021-04-23 12:06:35 +0200
commit1f8031f79a5f2af850d20dfff193e4d0571cb8d3 (patch)
treefdd3c88e8182b136650977972f9e6a478fcca29e /pceplib/pcep_msg_objects.c
parentMerge pull request #8536 from idryzhov/bfd-enabled (diff)
downloadfrr-1f8031f79a5f2af850d20dfff193e4d0571cb8d3.tar.xz
frr-1f8031f79a5f2af850d20dfff193e4d0571cb8d3.zip
*: make sure `config.h` or `zebra.h` is first
`config.h` has all the defines from autoconf, which may include things that switch behavior of other included headers (e.g. _GNU_SOURCE enabling prototypes for additional functions.) So, the first include in any `.c` file must be either `config.h` (with the appropriate guard) or `zebra.h` (which includes `config.h` first thing.) Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Diffstat (limited to 'pceplib/pcep_msg_objects.c')
-rw-r--r--pceplib/pcep_msg_objects.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/pceplib/pcep_msg_objects.c b/pceplib/pcep_msg_objects.c
index 6c943ddc2..e253fcc54 100644
--- a/pceplib/pcep_msg_objects.c
+++ b/pceplib/pcep_msg_objects.c
@@ -25,6 +25,10 @@
* This is the implementation of a High Level PCEP message object API.
*/
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
#include <string.h>
#include <arpa/inet.h>
#include <stdarg.h>