From 391e53fce16bab8e18e3e4e5694beb3615886ea5 Mon Sep 17 00:00:00 2001 From: Chris Cappuccio Date: Thu, 27 May 2021 21:44:38 -0700 Subject: [PATCH] Use TIOCOUTQ on systems where SIOCOUTQ is undefined --- src/tools/ipfixsend/ipfixsend.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/tools/ipfixsend/ipfixsend.c b/src/tools/ipfixsend/ipfixsend.c index 6d383c5f..6a3a2aaf 100644 --- a/src/tools/ipfixsend/ipfixsend.c +++ b/src/tools/ipfixsend/ipfixsend.c @@ -46,7 +46,9 @@ #include #include #include +#ifdef __linux__ #include +#endif #include #include "siso.h" @@ -268,6 +270,9 @@ int main(int argc, char** argv) // Make sure that all packets are delivered before socket closes int socket_fd = siso_get_socket(sender); int not_sent = 0; +#ifndef SIOCOUTQ +#define SIOCOUTQ TIOCOUTQ +#endif while (!stop && ioctl(socket_fd, SIOCOUTQ, ¬_sent) != -1) { if (not_sent <= 0) { break;