mirror of
https://github.com/curl/curl.git
synced 2026-07-23 08:57:18 +03:00
checksrc: find bad indentation in conditions without open brace
If the previous line starts with if/while/for AND ends with a closed parenthesis and there's an equal number of open and closed parentheses on that line, verify that this line is indented $indent more steps, if not a cpp line. Also adjust the fall-out from this fix. Closes #11054
This commit is contained in:
parent
31303c34e9
commit
9ce7eee070
17 changed files with 49 additions and 23 deletions
|
|
@ -884,7 +884,7 @@ ParameterError getparameter(const char *flag, /* f or -long-flag */
|
|||
ParameterError pe = GetSizeParameter(global, nextarg, "rate", &value);
|
||||
|
||||
if(pe != PARAM_OK)
|
||||
return pe;
|
||||
return pe;
|
||||
config->recvpersecond = value;
|
||||
config->sendpersecond = value;
|
||||
}
|
||||
|
|
@ -1060,7 +1060,7 @@ ParameterError getparameter(const char *flag, /* f or -long-flag */
|
|||
GetSizeParameter(global, nextarg, "max-filesize", &value);
|
||||
|
||||
if(pe != PARAM_OK)
|
||||
return pe;
|
||||
return pe;
|
||||
config->max_filesize = value;
|
||||
}
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -1878,7 +1878,7 @@ static CURLcode single_transfer(struct GlobalConfig *global,
|
|||
if(config->dns_ipv4_addr)
|
||||
my_setopt_str(curl, CURLOPT_DNS_LOCAL_IP4, config->dns_ipv4_addr);
|
||||
if(config->dns_ipv6_addr)
|
||||
my_setopt_str(curl, CURLOPT_DNS_LOCAL_IP6, config->dns_ipv6_addr);
|
||||
my_setopt_str(curl, CURLOPT_DNS_LOCAL_IP6, config->dns_ipv6_addr);
|
||||
|
||||
/* new in libcurl 7.6.2: */
|
||||
my_setopt_slist(curl, CURLOPT_TELNETOPTIONS, config->telnet_options);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue