]> git.ozlabs.org Git - ccan/commitdiff
altstack: Include config.h in run.c
authorDavid Gibson <david@gibson.dropbear.id.au>
Mon, 15 Feb 2016 11:43:07 +0000 (22:43 +1100)
committerDavid Gibson <david@gibson.dropbear.id.au>
Mon, 15 Feb 2016 11:43:07 +0000 (22:43 +1100)
ccan programs should always include config.h before anything else to make
sure everything is set up correctly.  Doing so in altstack's run.c means
it no longer needs an explicit _XOPEN_SOURCE 700, since _GNU_SOURCE is set
in config.h (for GNU libc, anyway).

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
ccan/altstack/test/run.c

index de94887284703977946feca870e07ce4bd9aee42..389ecb916b2f9d5089ab8fefa1e1ae951ee4c322 100644 (file)
@@ -1,3 +1,4 @@
+#include "config.h"
 #include <assert.h>
 #include <err.h>
 #include <errno.h>
@@ -8,7 +9,6 @@
 #include <sys/mman.h>
 #include <ccan/tap/tap.h>
 #include <ccan/altstack/altstack.h>
-#define _XOPEN_SOURCE 700
 #include <stdio.h>
 
 enum {