From 086146a3446817ca9ccd9cd1b201dd4c612d9700 Mon Sep 17 00:00:00 2001 From: xiongguangjie Date: Sat, 4 Jun 2022 14:05:51 +0800 Subject: [PATCH] try fix windows build error --- srt/Packet.cpp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/srt/Packet.cpp b/srt/Packet.cpp index 38c5c147..18ad279c 100644 --- a/srt/Packet.cpp +++ b/srt/Packet.cpp @@ -1,6 +1,16 @@  -#include "sys/socket.h" -#include "netdb.h" +#if defined(_WIN32) +#include +#include +#include +#pragma comment (lib, "Ws2_32.lib") +#pragma comment(lib,"Iphlpapi.lib") +#else +#include +#include +#endif // defined(_WIN32) + + #include #include "Util/logger.h"