From 3b548ffde9f0ea85dd320ae6af23a2e3fdbb6d29 Mon Sep 17 00:00:00 2001 From: Patrick Monnerat Date: Sat, 13 Jan 2018 01:20:40 +0100 Subject: setopt: reintroduce non-static Curl_vsetopt() for OS400 support This also upgrades ILE/RPG bindings with latest setopt options. Reported-By: jonrumsey on github Fixes #2230 Closes #2233 --- lib/setopt.c | 9 ++++----- lib/setopt.h | 4 +++- lib/url.h | 4 +--- 3 files changed, 8 insertions(+), 9 deletions(-) (limited to 'lib') diff --git a/lib/setopt.c b/lib/setopt.c index 49b7fac63..60f3ae5a6 100644 --- a/lib/setopt.c +++ b/lib/setopt.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2017, Daniel Stenberg, , et al. + * Copyright (C) 1998 - 2018, Daniel Stenberg, , et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -110,8 +110,8 @@ static CURLcode setstropt_userpwd(char *option, char **userp, char **passwdp) #define C_SSLVERSION_VALUE(x) (x & 0xffff) #define C_SSLVERSION_MAX_VALUE(x) (x & 0xffff0000) -static CURLcode setopt(struct Curl_easy *data, CURLoption option, - va_list param) +CURLcode Curl_vsetopt(struct Curl_easy *data, CURLoption option, + va_list param) { char *argptr; CURLcode result = CURLE_OK; @@ -2547,9 +2547,8 @@ CURLcode curl_easy_setopt(struct Curl_easy *data, CURLoption tag, ...) va_start(arg, tag); - result = setopt(data, tag, arg); + result = Curl_vsetopt(data, tag, arg); va_end(arg); return result; } - diff --git a/lib/setopt.h b/lib/setopt.h index 35769440f..c658e04ae 100644 --- a/lib/setopt.h +++ b/lib/setopt.h @@ -7,7 +7,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2017, Daniel Stenberg, , et al. + * Copyright (C) 1998 - 2018, Daniel Stenberg, , et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -23,5 +23,7 @@ ***************************************************************************/ CURLcode Curl_setstropt(char **charp, const char *s); +CURLcode Curl_vsetopt(struct Curl_easy *data, CURLoption option, + va_list arg); #endif /* HEADER_CURL_SETOPT_H */ diff --git a/lib/url.h b/lib/url.h index 0fdb8cf28..a70bd5466 100644 --- a/lib/url.h +++ b/lib/url.h @@ -7,7 +7,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2017, Daniel Stenberg, , et al. + * Copyright (C) 1998 - 2018, Daniel Stenberg, , et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -34,8 +34,6 @@ CURLcode Curl_init_do(struct Curl_easy *data, struct connectdata *conn); CURLcode Curl_open(struct Curl_easy **curl); CURLcode Curl_init_userdefined(struct Curl_easy *data); -CURLcode Curl_setopt(struct Curl_easy *data, CURLoption option, - va_list arg); CURLcode Curl_dupset(struct Curl_easy * dst, struct Curl_easy * src); void Curl_freeset(struct Curl_easy * data); CURLcode Curl_close(struct Curl_easy *data); /* opposite of curl_open() */ -- cgit v1.2.3