]> sigrok.org Git - libsigrok.git/blobdiff - hardware/common/scpi_tcp.c
filter.c: Work around const warning.
[libsigrok.git] / hardware / common / scpi_tcp.c
index 35119243c993a9bb2cab6a17c3aab8d251230798..8f4ea21dcdac8a844547c89dc6f68121e9d95b29 100644 (file)
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 
+#define _WIN32_WINNT 0x0501
+
 #include "libsigrok.h"
 #include "libsigrok-internal.h"
 
 #include <glib.h>
 #include <string.h>
 #include <unistd.h>
+#ifdef _WIN32
+#include <winsock2.h>
+#include <ws2tcpip.h>
+#else
 #include <sys/socket.h>
 #include <netinet/in.h>
 #include <arpa/inet.h>
 #include <netdb.h>
+#endif
 #include <errno.h>
 
 /* Message logging helpers with subsystem-specific prefix string. */