winetest: Initialize sin_zero field sockaddr_in structure (Coverity).
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
858064abf6
commit
2e97facdd0
|
@ -52,6 +52,7 @@ open_http (const char *server)
|
||||||
sa.sin_family = AF_INET;
|
sa.sin_family = AF_INET;
|
||||||
sa.sin_port = htons (80);
|
sa.sin_port = htons (80);
|
||||||
sa.sin_addr.s_addr = inet_addr (server);
|
sa.sin_addr.s_addr = inet_addr (server);
|
||||||
|
memset (sa.sin_zero, 0, sizeof(sa.sin_zero));
|
||||||
if (sa.sin_addr.s_addr == INADDR_NONE) {
|
if (sa.sin_addr.s_addr == INADDR_NONE) {
|
||||||
struct hostent *host = gethostbyname (server);
|
struct hostent *host = gethostbyname (server);
|
||||||
if (!host) {
|
if (!host) {
|
||||||
|
|
Loading…
Reference in New Issue