[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: getaddrinfo tests: fix test failure on MSVC
From: |
Gisle Vanem |
Subject: |
Re: getaddrinfo tests: fix test failure on MSVC |
Date: |
Wed, 3 Jul 2019 09:08:23 +0200 |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 |
Bruno Haible wrote:
On native Windows with MSVC, I observe this test failure:
FAIL: test-getaddrinfo
======================
FAIL test-getaddrinfo.exe (exit status: 4)
The cause is a missing call to WSAStartup(). This patch fixes it.
I found the same problem with test-select-fd.c:
--- a/tests/test-select-fd.c 2019-01-02 12:05:09
+++ b/tests/test-select-fd.c 2019-07-03 06:48:11
@@ -21,6 +21,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <sys/select.h>
+#include <sockets.h>
int
main (int argc, char *argv[])
@@ -44,6 +45,7 @@
struct timeval timeout;
int ret;
+ gl_sockets_startup (SOCKETS_1_1);
FD_ZERO (&fds);
FD_SET (fd, &fds);
timeout.tv_sec = 0;
--
--gv