diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2023-01-21 20:18:58 +0100 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2023-01-28 15:14:00 +0100 |
commit | fca78ca823e147665687d6cb0a6fe9a4694ba61b (patch) | |
tree | 3c37a13d67e5736d3d193f0e93de7db9a4cfb437 /src/core | |
parent | bbbd08694b025d62faad878bfd210e24f85f8c04 (diff) | |
download | weechat-fca78ca823e147665687d6cb0a6fe9a4694ba61b.zip |
core: make Curl constants and options case sensitive (issue #1872)
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/wee-url.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/core/wee-url.c b/src/core/wee-url.c index e5edbb920..b0d19a340 100644 --- a/src/core/wee-url.c +++ b/src/core/wee-url.c @@ -1027,9 +1027,12 @@ weeurl_search_constant (struct t_url_constant *constants, const char *name) { int i; + if (!name) + return -1; + for (i = 0; constants[i].name; i++) { - if (string_strcasecmp (constants[i].name, name) == 0) + if (strcmp (constants[i].name, name) == 0) { return i; } @@ -1090,9 +1093,12 @@ weeurl_search_option (const char *name) { int i; + if (!name) + return -1; + for (i = 0; url_options[i].name; i++) { - if (string_strcasecmp (url_options[i].name, name) == 0) + if (strcmp (url_options[i].name, name) == 0) { return i; } |