vtls_scache: avoid a "Redundant Condition"
Pointed out by CodeSonar. "ssl_config" can in fact not be NULL here. Made it an assert instead. Closes #15948
This commit is contained in:
parent
ca18198dd4
commit
d0607b27b0
@ -795,8 +795,9 @@ CURLcode Curl_ssl_scache_put(struct Curl_cfilter *cf,
|
||||
struct Curl_ssl_scache *scache = data->state.ssl_scache;
|
||||
struct ssl_config_data *ssl_config = Curl_ssl_cf_get_config(cf, data);
|
||||
CURLcode result;
|
||||
DEBUGASSERT(ssl_config);
|
||||
|
||||
if(!ssl_config || !scache || !ssl_config->primary.cache_session) {
|
||||
if(!scache || !ssl_config->primary.cache_session) {
|
||||
Curl_ssl_session_destroy(s);
|
||||
return CURLE_OK;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user