summaryrefslogtreecommitdiff
path: root/lib/http.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2021-03-26 13:08:44 +0100
committerDaniel Stenberg <daniel@haxx.se>2021-03-27 12:38:28 +0100
commitb5726e5549a45671391e88e45b9e0702ff4e7a28 (patch)
treee7f22eae0b8883c45ad7572ab621e7b85c7ff6f1 /lib/http.c
parent24e469f6d61635f85bd4a0845c07aef0c6be661b (diff)
downloadcurl-b5726e5549a45671391e88e45b9e0702ff4e7a28.tar.gz
send_speed: simplify the checks for if a speed limit is set
... as we know the value cannot be set to negative: enforced by setopt()
Diffstat (limited to 'lib/http.c')
-rw-r--r--lib/http.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/http.c b/lib/http.c
index a0da9eade..02c81c419 100644
--- a/lib/http.c
+++ b/lib/http.c
@@ -1167,7 +1167,7 @@ static size_t readmoredata(char *buffer,
/* make sure that a HTTP request is never sent away chunked! */
data->req.forbidchunk = (http->sending == HTTPSEND_REQUEST)?TRUE:FALSE;
- if((data->set.max_send_speed > 0) &&
+ if(data->set.max_send_speed &&
(data->set.max_send_speed < http->postsize))
/* speed limit */
fullsize = (size_t)data->set.max_send_speed;