mirror of
https://github.com/curl/curl.git
synced 2026-08-25 17:33:32 +03:00
lib: reduce variable scopes
Fixes Codacy/CppCheck warnings. Closes https://github.com/curl/curl/pull/3872
This commit is contained in:
parent
27af2ec219
commit
10db3ef21e
23 changed files with 115 additions and 124 deletions
|
|
@ -605,9 +605,9 @@ static CURLUcode hostname_check(struct Curl_URL *u, char *hostname)
|
|||
/* only valid letters are ok */
|
||||
len = strspn(hostname, l);
|
||||
if(hlen != len) {
|
||||
/* this could now be '%[zone id]' */
|
||||
char zoneid[16];
|
||||
if(hostname[len] == '%') {
|
||||
/* this could now be '%[zone id]' */
|
||||
char zoneid[16];
|
||||
int i = 0;
|
||||
char *h = &hostname[len + 1];
|
||||
/* pass '25' if present and is a url encoded percent sign */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue