From 09e3a4e4ec17102e6daeee792ae02c1a8601b5eb Mon Sep 17 00:00:00 2001 From: Ralf Baechle Date: Wed, 26 Jul 2017 00:21:27 +0200 Subject: ax25ipd: Fix glibc feature selection macros. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This fixes the following warnings: gcc -DHAVE_CONFIG_H -I. -I.. -DAX25_SYSCONFDIR=\""/usr/local/etc/ax25"\" -DAX25_LOCALSTATEDIR=\""/usr/local/var/ax25"\" -g -O2 -Wall -MT io.o -MD -MP -MF .deps/io.Tpo -c -o io.o io.c io.c: In function ‘io_open’: io.c:324:18: warning: implicit declaration of function ‘ptsname’; did you mean ‘ttyname’? [-Wimplicit-function-declaration] if ((namepts = ptsname(ttyfd)) == NULL) { ^~~~~~~ ttyname io.c:324:16: warning: assignment makes pointer from integer without a cast [-Wint-conversion] if ((namepts = ptsname(ttyfd)) == NULL) { ^ io.c:329:7: warning: implicit declaration of function ‘unlockpt’; did you mean ‘unlinkat’? [-Wimplicit-function-declaration] if (unlockpt(ttyfd) == -1) { ^~~~~~~~ unlinkat Signed-off-by: Ralf Baechle --- ax25ipd/io.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ax25ipd/io.c b/ax25ipd/io.c index e441131..56ef30f 100644 --- a/ax25ipd/io.c +++ b/ax25ipd/io.c @@ -8,6 +8,8 @@ * This is also the key dispatching module, so it knows about a lot more * than just I/O stuff. */ +#define _XOPEN_SOURCE +#define _XOPEN_SOURCE_EXTENDED #include #include -- cgit v1.2.3