mirror of
https://github.com/curl/curl.git
synced 2026-07-29 00:03:12 +03:00
setopt: warn on Curl_set*opt() uses not using the return value
And switch the invokes that would "set" NULL to instead just plainly free the pointer, as those were otherwise the invokes that would ignore the return code. And possibly confuse static code analyzers. Closes #13591
This commit is contained in:
parent
c8925f3ec3
commit
efe93019a7
2 changed files with 11 additions and 9 deletions
|
|
@ -24,9 +24,10 @@
|
|||
*
|
||||
***************************************************************************/
|
||||
|
||||
CURLcode Curl_setstropt(char **charp, const char *s);
|
||||
CURLcode Curl_setstropt(char **charp, const char *s) WARN_UNUSED_RESULT;
|
||||
CURLcode Curl_setblobopt(struct curl_blob **blobp,
|
||||
const struct curl_blob *blob);
|
||||
CURLcode Curl_vsetopt(struct Curl_easy *data, CURLoption option, va_list arg);
|
||||
const struct curl_blob *blob) WARN_UNUSED_RESULT;
|
||||
CURLcode Curl_vsetopt(struct Curl_easy *data, CURLoption option, va_list arg)
|
||||
WARN_UNUSED_RESULT;
|
||||
|
||||
#endif /* HEADER_CURL_SETOPT_H */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue