diff options
author | Daniel Stenberg <daniel@haxx.se> | 2017-09-09 23:09:06 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2017-09-11 09:29:50 +0200 |
commit | 6b84438d9a9220fb75cbaae9d6fe6c3edb6d425e (patch) | |
tree | 109c29611f5bd2dbedab015b45524e8ffe6e1057 /lib/escape.c | |
parent | e155f38d1eaa89cc8ce2a6536b74be2954506bb0 (diff) | |
download | curl-6b84438d9a9220fb75cbaae9d6fe6c3edb6d425e.tar.gz |
code style: use spaces around equals signs
Diffstat (limited to 'lib/escape.c')
-rw-r--r-- | lib/escape.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/escape.c b/lib/escape.c index 973aeb6ea..00c10b14a 100644 --- a/lib/escape.c +++ b/lib/escape.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -84,7 +84,7 @@ char *curl_easy_escape(struct Curl_easy *data, const char *string, char *testing_ptr = NULL; unsigned char in; /* we need to treat the characters unsigned */ size_t newlen; - size_t strindex=0; + size_t strindex = 0; size_t length; CURLcode result; @@ -104,7 +104,7 @@ char *curl_easy_escape(struct Curl_easy *data, const char *string, if(Curl_isunreserved(in)) /* just copy this */ - ns[strindex++]=in; + ns[strindex++] = in; else { /* encode it */ newlen += 2; /* the size grows with two, since this'll become a %XX */ @@ -125,11 +125,11 @@ char *curl_easy_escape(struct Curl_easy *data, const char *string, snprintf(&ns[strindex], 4, "%%%02X", in); - strindex+=3; + strindex += 3; } string++; } - ns[strindex]=0; /* terminate it */ + ns[strindex] = 0; /* terminate it */ return ns; } @@ -151,7 +151,7 @@ CURLcode Curl_urldecode(struct Curl_easy *data, size_t alloc = (length?length:strlen(string))+1; char *ns = malloc(alloc); unsigned char in; - size_t strindex=0; + size_t strindex = 0; unsigned long hex; CURLcode result; @@ -180,8 +180,8 @@ CURLcode Curl_urldecode(struct Curl_easy *data, return result; } - string+=2; - alloc-=2; + string += 2; + alloc -= 2; } if(reject_ctrl && (in < 0x20)) { @@ -192,7 +192,7 @@ CURLcode Curl_urldecode(struct Curl_easy *data, ns[strindex++] = in; string++; } - ns[strindex]=0; /* terminate it */ + ns[strindex] = 0; /* terminate it */ if(olen) /* store output size */ |