summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2015-03-20 15:32:02 +0000
committerIngo Schwarze <schwarze@openbsd.org>2015-03-20 15:32:02 +0000
commitcc5aae7a86394f4fc3ae1ace0f95e4a29ec61914 (patch)
treeb655416e53989f79f50953949da16f9ec81b0063
parente288630db51bbfcab093f985392465505099da6d (diff)
downloadmandoc-cc5aae7a86394f4fc3ae1ace0f95e4a29ec61914.tar.gz
vasprintf(3) needs _GNU_SOURCE on Linux;
pointed out by Christian Neukirchen <chneukirchen at gmail dot com>.
-rw-r--r--test-vasprintf.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/test-vasprintf.c b/test-vasprintf.c
index 06fe5d61..dd22b9d9 100644
--- a/test-vasprintf.c
+++ b/test-vasprintf.c
@@ -15,6 +15,10 @@
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
+#if defined(__linux__) || defined(__MINT__)
+#define _GNU_SOURCE /* vasprintf() */
+#endif
+
#include <stdarg.h>
#include <stdio.h>
#include <string.h>