Replace _BSD_SOURCE with _DEFAULT_SOURCE

Silence warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"

http://man7.org/tlpi/code/faq.html#use_default_source

Closes: https://pagure.io/freeipa/issue/6818
Signed-off-by: Christian Heimes <cheimes@redhat.com>
Reviewed-By: Simo Sorce <ssorce@redhat.com>
This commit is contained in:
Christian Heimes
2017-04-24 11:15:43 +02:00
committed by Martin Basti
parent ad08430477
commit 9b443b908f
2 changed files with 3 additions and 2 deletions

View File

@@ -76,4 +76,5 @@ noinst_LTLIBRARIES=libasn1c.la
regenerate:
asn1c -fskeletons-copy -fnative-types ipa.asn1
$(SED) -i s/_BSD_SOURCE/_DEFAULT_SOURCE/g asn_system.h
rm -f converter-sample.c Makefile.am.sample

View File

@@ -13,8 +13,8 @@
#include "config.h"
#endif
#ifndef _BSD_SOURCE
#define _BSD_SOURCE /* for snprintf() on some linux systems */
#ifndef _DEFAULT_SOURCE
#define _DEFAULT_SOURCE /* for snprintf() on some linux systems */
#endif
#include <stdio.h> /* For snprintf(3) */