summaryrefslogtreecommitdiff
path: root/lib/vtls/schannel.c
diff options
context:
space:
mode:
authorMarcel Raad <Marcel.Raad@teamviewer.com>2019-09-22 19:04:18 +0200
committerMarcel Raad <Marcel.Raad@teamviewer.com>2019-09-23 09:44:35 +0200
commit527461285f54bca59356e2c550d55ed9606e96d1 (patch)
treefcddc2509c4de4c6ff2eaf8f8fe2359a59f37d6f /lib/vtls/schannel.c
parent96a3ab7bc8fcf731322e6d141f5eb8e4ad856e1a (diff)
downloadcurl-527461285f54bca59356e2c550d55ed9606e96d1.tar.gz
vtls: fix narrowing conversion warnings
Curl_timeleft returns `timediff_t`, which is 64 bits wide also on 32-bit systems since commit b1616dad8f0. Closes https://github.com/curl/curl/pull/4398
Diffstat (limited to 'lib/vtls/schannel.c')
-rw-r--r--lib/vtls/schannel.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/vtls/schannel.c b/lib/vtls/schannel.c
index 0f6f734fd..37273135c 100644
--- a/lib/vtls/schannel.c
+++ b/lib/vtls/schannel.c
@@ -1347,7 +1347,7 @@ schannel_connect_common(struct connectdata *conn, int sockindex,
struct Curl_easy *data = conn->data;
struct ssl_connect_data *connssl = &conn->ssl[sockindex];
curl_socket_t sockfd = conn->sock[sockindex];
- time_t timeout_ms;
+ timediff_t timeout_ms;
int what;
/* check if the connection has already been established */
@@ -1394,7 +1394,7 @@ schannel_connect_common(struct connectdata *conn, int sockindex,
connssl->connecting_state ? sockfd : CURL_SOCKET_BAD;
what = Curl_socket_check(readfd, CURL_SOCKET_BAD, writefd,
- nonblocking ? 0 : timeout_ms);
+ nonblocking ? 0 : (time_t)timeout_ms);
if(what < 0) {
/* fatal error */
failf(data, "select/poll on SSL/TLS socket, errno: %d", SOCKERRNO);
@@ -1544,7 +1544,7 @@ schannel_send(struct connectdata *conn, int sockindex,
/* send entire message or fail */
while(len > (size_t)written) {
ssize_t this_write;
- time_t timeleft;
+ timediff_t timeleft;
int what;
this_write = 0;