[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnurl] 96/411: easygetopt: pass a valid enum to avoid compiler warning
From: |
gnunet |
Subject: |
[gnurl] 96/411: easygetopt: pass a valid enum to avoid compiler warning |
Date: |
Wed, 13 Jan 2021 01:18:31 +0100 |
This is an automated email from the git hooks/post-receive script.
nikita pushed a commit to branch master
in repository gnurl.
commit 879007f8118771f4896334731aaca5850a154675
Author: Daniel Stenberg <daniel@haxx.se>
AuthorDate: Sat Sep 5 12:52:03 2020 +0200
easygetopt: pass a valid enum to avoid compiler warning
"integer constant not in range of enumerated type 'CURLoption'"
Reported-by: Gisle Vanem
Bug:
https://github.com/curl/curl/commit/6ebe63fac23f38df911edc348e8ccc72280f9434#commitcomment-42042843
Closes #5915
---
lib/easygetopt.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lib/easygetopt.c b/lib/easygetopt.c
index c4c6f631c..cac8378e7 100644
--- a/lib/easygetopt.c
+++ b/lib/easygetopt.c
@@ -51,7 +51,8 @@ static struct curl_easyoption *lookup(const char *name,
CURLoption id)
const struct curl_easyoption *curl_easy_option_by_name(const char *name)
{
- return lookup(name, 0);
+ /* when name is used, the id argument is ignored */
+ return lookup(name, CURLOPT_LASTENTRY);
}
const struct curl_easyoption *curl_easy_option_by_id(CURLoption id)
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [gnurl] 115/411: lib: fix -Wassign-enum warnings, (continued)
- [gnurl] 115/411: lib: fix -Wassign-enum warnings, gnunet, 2021/01/12
- [gnurl] 118/411: curl_mime_headers.3: fix the example's use of curl_slist_append, gnunet, 2021/01/12
- [gnurl] 113/411: url: use blank credentials when using proxy w/o username and password, gnunet, 2021/01/12
- [gnurl] 136/411: ftp: a 550 response to SIZE returns CURLE_REMOTE_FILE_NOT_FOUND, gnunet, 2021/01/12
- [gnurl] 134/411: curl: make glob_match_url use dynbuf, gnunet, 2021/01/12
- [gnurl] 105/411: CI/azure: add test number to title for display in analytics, gnunet, 2021/01/12
- [gnurl] 87/411: http_proxy: do not crash with HTTPS_PROXY and NO_PROXY set, gnunet, 2021/01/12
- [gnurl] 102/411: tests: remove pipelining tests, gnunet, 2021/01/12
- [gnurl] 126/411: dynbuf: provide curlx_ names for reuse by the curl tool, gnunet, 2021/01/12
- [gnurl] 121/411: HISTORY: mention alt-svc added in 2019, gnunet, 2021/01/12
- [gnurl] 96/411: easygetopt: pass a valid enum to avoid compiler warning,
gnunet <=
- [gnurl] 94/411: tool: update --help with categories, gnunet, 2021/01/12
- [gnurl] 104/411: altsvc: clone setting in curl_easy_duphandle, gnunet, 2021/01/12
- [gnurl] 112/411: travis: add a build using libressl (from git master), gnunet, 2021/01/12
- [gnurl] 131/411: imap: set cselect_bits to CURL_CSELECT_IN initially, gnunet, 2021/01/12
- [gnurl] 128/411: runtests: allow creating files without newlines, gnunet, 2021/01/12
- [gnurl] 147/411: TODO: add PR reference for native IDN support on macOS, gnunet, 2021/01/12
- [gnurl] 155/411: ftp: get rid of the PPSENDF macro, gnunet, 2021/01/12
- [gnurl] 167/411: parsedate: tune the date to epoch conversion, gnunet, 2021/01/12
- [gnurl] 146/411: tool_help.h: update copyright year range, gnunet, 2021/01/12
- [gnurl] 164/411: docs/MQTT: not experimental anymore, gnunet, 2021/01/12