aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Holme <steve_holme@hotmail.com>2014-12-27 17:42:21 +0000
committerSteve Holme <steve_holme@hotmail.com>2014-12-27 17:46:25 +0000
commitfd281e9c4b23215a0ed1bddf034d7a0ed83b0178 (patch)
treeda3da82c27387497bcfad8187dfaa038f23944c3
parente0d265d3eb86bda6ef18bc605f9273f073418bf7 (diff)
getinfo: Use 'CURLcode result' for curl result codes
-rw-r--r--lib/getinfo.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/lib/getinfo.c b/lib/getinfo.c
index 4c3dc1387..3f21c94d1 100644
--- a/lib/getinfo.c
+++ b/lib/getinfo.c
@@ -340,10 +340,10 @@ CURLcode Curl_getinfo(struct SessionHandle *data, CURLINFO info, ...)
struct curl_slist **param_slistp=NULL;
int type;
/* default return code is to error out! */
- CURLcode ret = CURLE_BAD_FUNCTION_ARGUMENT;
+ CURLcode result = CURLE_BAD_FUNCTION_ARGUMENT;
if(!data)
- return ret;
+ return result;
va_start(arg, info);
@@ -352,27 +352,28 @@ CURLcode Curl_getinfo(struct SessionHandle *data, CURLINFO info, ...)
case CURLINFO_STRING:
param_charp = va_arg(arg, char **);
if(NULL != param_charp)
- ret = getinfo_char(data, info, param_charp);
+ result = getinfo_char(data, info, param_charp);
break;
case CURLINFO_LONG:
param_longp = va_arg(arg, long *);
if(NULL != param_longp)
- ret = getinfo_long(data, info, param_longp);
+ result = getinfo_long(data, info, param_longp);
break;
case CURLINFO_DOUBLE:
param_doublep = va_arg(arg, double *);
if(NULL != param_doublep)
- ret = getinfo_double(data, info, param_doublep);
+ result = getinfo_double(data, info, param_doublep);
break;
case CURLINFO_SLIST:
param_slistp = va_arg(arg, struct curl_slist **);
if(NULL != param_slistp)
- ret = getinfo_slist(data, info, param_slistp);
+ result = getinfo_slist(data, info, param_slistp);
break;
default:
break;
}
va_end(arg);
- return ret;
+
+ return result;
}