[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnurl] 131/163: telnet: fix clang warnings
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnurl] 131/163: telnet: fix clang warnings |
Date: |
Sun, 05 Aug 2018 12:37:37 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit ab4cf99694fc5a028c4eb7abdc4891919b57a32e
Author: Gisle Vanem <address@hidden>
AuthorDate: Fri Jun 29 23:22:19 2018 +0200
telnet: fix clang warnings
telnet.c(1401,28): warning: cast from function call of type 'int' to
non-matching type 'HANDLE' (aka 'void *') [-Wbad-function-cast]
Fixes #2696
Closes #2700
---
lib/telnet.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/telnet.c b/lib/telnet.c
index b04d30bb9..fff3f3378 100644
--- a/lib/telnet.c
+++ b/lib/telnet.c
@@ -92,6 +92,7 @@
#endif
#ifdef USE_WINSOCK
+typedef WSAEVENT (WINAPI *WSOCK2_EVENT)(void);
typedef FARPROC WSOCK2_FUNC;
static CURLcode check_wsock2(struct Curl_easy *data);
#endif
@@ -1306,7 +1307,7 @@ static CURLcode telnet_do(struct connectdata *conn, bool
*done)
#ifdef USE_WINSOCK
HMODULE wsock2;
WSOCK2_FUNC close_event_func;
- WSOCK2_FUNC create_event_func;
+ WSOCK2_EVENT create_event_func;
WSOCK2_FUNC event_select_func;
WSOCK2_FUNC enum_netevents_func;
WSAEVENT event_handle;
@@ -1360,7 +1361,7 @@ static CURLcode telnet_do(struct connectdata *conn, bool
*done)
}
/* Grab a pointer to WSACreateEvent */
- create_event_func = GetProcAddress(wsock2, "WSACreateEvent");
+ create_event_func = (WSOCK2_EVENT) GetProcAddress(wsock2, "WSACreateEvent");
if(create_event_func == NULL) {
failf(data, "failed to find WSACreateEvent function (%u)", GetLastError());
FreeLibrary(wsock2);
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [gnurl] 106/163: CURLOPT_INTERFACE.3: interface names not supported on Windows, (continued)
- [GNUnet-SVN] [gnurl] 106/163: CURLOPT_INTERFACE.3: interface names not supported on Windows, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 122/163: getnameinfo: not used, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 100/163: docs/RELEASE-PROCEDURE.md: renamed to use .md extension, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 111/163: multi: fix crash due to dangling entry in connect-pending list, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 116/163: include/README: remove "hacking" advice, not the right place, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 118/163: GOVERNANCE: add maintainer details/duties, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 113/163: netrc: use a larger buffer, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 103/163: maketgz: delete .bak files, fix indentation, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 97/163: CURLOPT_HTTPAUTH.3: CURLAUTH_BEARER was added in 7.61.0, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 148/163: examples: fix -Wformat warnings, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 131/163: telnet: fix clang warnings,
gnunet <=
- [GNUnet-SVN] [gnurl] 137/163: RELEASE-NOTES: synced, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 127/163: RELEASE-NOTES: synced, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 147/163: smtp: use the upload buffer size for scratch buffer malloc, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 125/163: CURLINFO_TLS_SSL_PTR.3: improve the example, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 160/163: gnurl: post-merge adjustments, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 152/163: schannel: fix -Wsign-compare warning, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 151/163: schannel: workaround for wrong function signature in w32api, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 158/163: release: 7.61.0, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 155/163: CMake: remove redundant and old end-of-block syntax, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 115/163: RELEASE-NOTES: synced, gnunet, 2018/08/05