diff options
author | Daniel Stenberg <daniel@haxx.se> | 2016-09-30 17:15:05 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2016-10-31 08:46:35 +0100 |
commit | 502acba2af821391b85a2cd4ac7b91ad8e9d4180 (patch) | |
tree | e219be1178db413bffd92033e965c1e1075c4702 /tests/server/sws.c | |
parent | 1833a45dde4d27febfce42813699533b1ae993d1 (diff) | |
download | curl-502acba2af821391b85a2cd4ac7b91ad8e9d4180.tar.gz |
strcasecompare: is the new name for strequal()
... to make it less likely that we forget that the function actually
does case insentive compares. Also replaced several invokes of the
function with a plain strcmp when case sensitivity is not an issue (like
comparing with "-").
Diffstat (limited to 'tests/server/sws.c')
-rw-r--r-- | tests/server/sws.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/server/sws.c b/tests/server/sws.c index 27c86e013..801a7b83f 100644 --- a/tests/server/sws.c +++ b/tests/server/sws.c @@ -697,7 +697,7 @@ static int ProcessRequest(struct httprequest *req) if(got_exit_signal) return 1; /* done */ - if((req->cl==0) && curlx_strnequal("Content-Length:", line, 15)) { + if((req->cl==0) && curlx_strncasecompare("Content-Length:", line, 15)) { /* If we don't ignore content-length, we read it and we read the whole request including the body before we return. If we've been told to ignore the content-length, we will return as soon as all headers @@ -723,8 +723,8 @@ static int ProcessRequest(struct httprequest *req) logmsg("... but will abort after %zu bytes", req->cl); break; } - else if(curlx_strnequal("Transfer-Encoding: chunked", line, - strlen("Transfer-Encoding: chunked"))) { + else if(curlx_strncasecompare("Transfer-Encoding: chunked", line, + strlen("Transfer-Encoding: chunked"))) { /* chunked data coming in */ chunked = TRUE; } |