aboutsummaryrefslogtreecommitdiff
path: root/src/tool_operate.c
diff options
context:
space:
mode:
authorDaniel Gustafsson <daniel@yesql.se>2018-04-25 21:53:27 +0200
committerDaniel Stenberg <daniel@haxx.se>2018-04-27 00:51:35 +0200
commit2f13e3d23d9acd448b1e1e2cad419b4c118c43e4 (patch)
tree9dc0c85afa6f373af02b03734c8c4d12f60d1667 /src/tool_operate.c
parent1d71ce845a6ac3887205c2842fad0a476f7cf3ec (diff)
checksrc: force indentation of lines after an else
This extends the INDENTATION case to also handle 'else' statements and require proper indentation on the following line. Also fixes the offending cases found in the codebase. Closes #2532
Diffstat (limited to 'src/tool_operate.c')
-rw-r--r--src/tool_operate.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/tool_operate.c b/src/tool_operate.c
index 932dda6e0..626c30888 100644
--- a/src/tool_operate.c
+++ b/src/tool_operate.c
@@ -456,8 +456,7 @@ static CURLcode operate_do(struct GlobalConfig *global,
the number of resources as urlnum. */
urlnum = count_next_metalink_resource(mlfile);
}
- else
- if(!config->globoff) {
+ else if(!config->globoff) {
/* Unless explicitly shut off, we expand '{...}' and '[...]'
expressions and return total number of URLs in pattern set */
result = glob_url(&urls, urlnode->url, &urlnum,
@@ -1858,8 +1857,7 @@ static CURLcode operate_do(struct GlobalConfig *global,
*/
break;
}
- else
- if(urlnum > 1) {
+ else if(urlnum > 1) {
/* when url globbing, exit loop upon critical error */
if(is_fatal_error(result))
break;