BUILD: make proto_tcp.c compatible with musl library

musl library expose tcp_info structure only when _GNU_SOURCE is defined.
This is required to build HAProxy on OSes relying musl such as Alpine
Linux.
This commit is contained in:
Baptiste Assmann 2016-08-08 14:12:08 +02:00 committed by Willy Tarreau
parent aa1ea8a9ee
commit 39a5f22c36

View File

@ -10,6 +10,11 @@
*
*/
/* this is to have tcp_info defined on systems using musl
* library, such as Alpine Linux
*/
#define _GNU_SOURCE
#include <ctype.h>
#include <errno.h>
#include <fcntl.h>