[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnurl] 152/163: schannel: fix -Wsign-compare warning
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnurl] 152/163: schannel: fix -Wsign-compare warning |
Date: |
Sun, 05 Aug 2018 12:37:58 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit 424f1cfefbace57e5873e614a43ff14b251bbc7e
Author: Marcel Raad <address@hidden>
AuthorDate: Sun Jul 8 17:16:34 2018 +0200
schannel: fix -Wsign-compare warning
MinGW warns:
/lib/vtls/schannel.c:219:64: warning: signed and unsigned type in
conditional expression [-Wsign-compare]
Fix this by casting the ptrdiff_t to size_t as we know it's positive.
Closes https://github.com/curl/curl/pull/2721
---
lib/vtls/schannel.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/vtls/schannel.c b/lib/vtls/schannel.c
index b72542225..382efb525 100644
--- a/lib/vtls/schannel.c
+++ b/lib/vtls/schannel.c
@@ -216,7 +216,7 @@ get_alg_id_by_name(char *name)
{
char tmp[LONGEST_ALG_ID] = { 0 };
char *nameEnd = strchr(name, ':');
- size_t n = nameEnd ? min(nameEnd - name, LONGEST_ALG_ID - 1) : \
+ size_t n = nameEnd ? min((size_t)(nameEnd - name), LONGEST_ALG_ID - 1) : \
min(strlen(name), LONGEST_ALG_ID - 1);
strncpy(tmp, name, n);
tmp[n] = 0;
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [gnurl] 113/163: netrc: use a larger buffer, (continued)
- [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, 2018/08/05
- [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 <=
- [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
- [GNUnet-SVN] [gnurl] 145/163: darwinssl: allow High Sierra users to build the code using GCC, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 141/163: libssh: goto DISCONNECT state on error, not SSH_SESSION_FREE, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 130/163: docs: fix missed option name markups, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 156/163: post303.d: clarify that this is an RFC violation, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 139/163: KNOWN_BUGS: Borland support is dropped, AIX problem is too old, gnunet, 2018/08/05
- [GNUnet-SVN] [gnurl] 119/163: GOVERNANCE: linkify, changed some titles, gnunet, 2018/08/05