diff options
author | Daniel Stenberg <daniel@haxx.se> | 2006-02-01 23:26:14 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2006-02-01 23:26:14 +0000 |
commit | 54cbd7e15445f3fa5881255c0d8282a61e4617e6 (patch) | |
tree | edbee08548f59c376fed3ed603795ce9bf382aa6 /src | |
parent | 5994b62930c004deccff61b7670ebf6debadfaa2 (diff) |
Make --limit-rate [num] mean bytes. Seems I broke it back in november 2005...
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c index 549a4d892..6651bcf9a 100644 --- a/src/main.c +++ b/src/main.c @@ -1512,7 +1512,9 @@ static ParameterError getparameter(char *flag, /* f or -long-flag */ char *unit; curl_off_t value = curlx_strtoofft(nextarg, &unit, 0); - if(strlen(unit) != 1) + if(!*unit) + unit="b"; + else if(strlen(unit) > 1) unit=(char *)"w"; /* unsupported */ switch(*unit) { |