From 6b84438d9a9220fb75cbaae9d6fe6c3edb6d425e Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Sat, 9 Sep 2017 23:09:06 +0200 Subject: code style: use spaces around equals signs --- src/tool_setopt.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/tool_setopt.c') diff --git a/src/tool_setopt.c b/src/tool_setopt.c index a8e205938..fd9bba4d6 100644 --- a/src/tool_setopt.c +++ b/src/tool_setopt.c @@ -229,24 +229,24 @@ static char *c_escape(const char *str, size_t len) return NULL; e = escaped; - for(s=str; (c=*s) != '\0'; s++) { - if(c=='\n') { + for(s = str; (c = *s) != '\0'; s++) { + if(c == '\n') { strcpy(e, "\\n"); e += 2; } - else if(c=='\r') { + else if(c == '\r') { strcpy(e, "\\r"); e += 2; } - else if(c=='\t') { + else if(c == '\t') { strcpy(e, "\\t"); e += 2; } - else if(c=='\\') { + else if(c == '\\') { strcpy(e, "\\\\"); e += 2; } - else if(c=='"') { + else if(c == '"') { strcpy(e, "\\\""); e += 2; } @@ -276,7 +276,7 @@ CURLcode tool_setopt_enum(CURL *curl, struct GlobalConfig *config, if(config->libcurl && !skip && !ret) { /* we only use this for real if --libcurl was used */ const NameValue *nv = NULL; - for(nv=nvlist; nv->name; nv++) { + for(nv = nvlist; nv->name; nv++) { if(nv->value == lval) break; /* found it */ } if(! nv->name) { @@ -313,7 +313,7 @@ CURLcode tool_setopt_flags(CURL *curl, struct GlobalConfig *config, const NameValue *nv = NULL; snprintf(preamble, sizeof(preamble), "curl_easy_setopt(hnd, %s, ", name); - for(nv=nvlist; nv->name; nv++) { + for(nv = nvlist; nv->name; nv++) { if((nv->value & ~ rest) == 0) { /* all value flags contained in rest */ rest &= ~ nv->value; /* remove bits handled here */ @@ -356,7 +356,7 @@ CURLcode tool_setopt_bitmask(CURL *curl, struct GlobalConfig *config, const NameValueUnsigned *nv = NULL; snprintf(preamble, sizeof(preamble), "curl_easy_setopt(hnd, %s, ", name); - for(nv=nvlist; nv->name; nv++) { + for(nv = nvlist; nv->name; nv++) { if((nv->value & ~ rest) == 0) { /* all value flags contained in rest */ rest &= ~ nv->value; /* remove bits handled here */ @@ -632,7 +632,7 @@ CURLcode tool_setopt(CURL *curl, bool str, struct GlobalConfig *config, long lval = va_arg(arg, long); long defval = 0L; const NameValue *nv = NULL; - for(nv=setopt_nv_CURLNONZERODEFAULTS; nv->name; nv++) { + for(nv = setopt_nv_CURLNONZERODEFAULTS; nv->name; nv++) { if(!strcmp(name, nv->name)) { defval = nv->value; break; /* found it */ -- cgit v1.2.3