mirror of
https://github.com/curl/curl.git
synced 2026-06-04 15:54:17 +03:00
tool: return code variable consistency
- ParameterError variables are named 'err' - CURLcode variables are named 'result' For naming consistency across functions Closes #20426
This commit is contained in:
parent
4e5908306a
commit
d0dc6e2ec0
8 changed files with 301 additions and 293 deletions
|
|
@ -251,9 +251,9 @@ ParameterError oct2nummax(long *val, const char *str, long max)
|
|||
|
||||
ParameterError str2unum(long *val, const char *str)
|
||||
{
|
||||
ParameterError result = str2num(val, str);
|
||||
if(result != PARAM_OK)
|
||||
return result;
|
||||
ParameterError err = str2num(val, str);
|
||||
if(err != PARAM_OK)
|
||||
return err;
|
||||
if(*val < 0)
|
||||
return PARAM_NEGATIVE_NUMERIC;
|
||||
|
||||
|
|
@ -272,9 +272,9 @@ ParameterError str2unum(long *val, const char *str)
|
|||
|
||||
ParameterError str2unummax(long *val, const char *str, long max)
|
||||
{
|
||||
ParameterError result = str2unum(val, str);
|
||||
if(result != PARAM_OK)
|
||||
return result;
|
||||
ParameterError err = str2unum(val, str);
|
||||
if(err != PARAM_OK)
|
||||
return err;
|
||||
if(*val > max)
|
||||
return PARAM_NUMBER_TOO_LARGE;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue