From 037cd0d99159cd39b8e1217ad9a9362e7ab0b746 Mon Sep 17 00:00:00 2001 From: Steve Holme Date: Sun, 28 Dec 2014 17:21:02 +0000 Subject: vtls: Fixed compilation warning and an ignored return code curl_schannel.h:123: warning: right-hand operand of comma expression has no effect Some instances of the curlssl_close_all() function were declared with a void return type whilst others as int. The schannel version returned CURLE_NOT_BUILT_IN and others simply returned zero, but in all cases the return code was ignored by the calling function Curl_ssl_close_all(). For the time being and to keep the internal API consistent, changed all declarations to use a void return type. To reduce code we might want to consider removing the unimplemented versions and use a void #define like schannel does. --- lib/vtls/openssl.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib/vtls/openssl.c') diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index a41447a5b..a68d88eae 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -1038,7 +1038,7 @@ void Curl_ossl_session_free(void *ptr) * This function is called when the 'data' struct is going away. Close * down everything and free all resources! */ -int Curl_ossl_close_all(struct SessionHandle *data) +void Curl_ossl_close_all(struct SessionHandle *data) { #ifdef HAVE_OPENSSL_ENGINE_H if(data->state.engine) { @@ -1049,7 +1049,6 @@ int Curl_ossl_close_all(struct SessionHandle *data) #else (void)data; #endif - return 0; } static int asn1_output(const ASN1_UTCTIME *tm, -- cgit v1.2.3