]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
vtls: remove duplicate assign
authorDaniel Stenberg <daniel@haxx.se>
Mon, 13 May 2024 18:00:23 +0000 (20:00 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 14 May 2024 05:58:59 +0000 (07:58 +0200)
Curl_ssl_peer_cleanup() already clears the ->sni field, no point in
assigning it again.

Spotted by CodeSonar

Closes #13626

lib/vtls/vtls.c

index af7ebe65c5b990d35770a1b14587eeb8f37e417b..570a10d5ac664f3ec672abbee238b8cadf905220 100644 (file)
@@ -1603,7 +1603,6 @@ CURLcode Curl_ssl_peer_init(struct ssl_peer *peer, struct Curl_cfilter *cf,
       }
     }
 
-    peer->sni = NULL;
     peer->type = get_peer_type(peer->hostname);
     if(peer->type == CURL_SSL_PEER_DNS && peer->hostname[0]) {
       /* not an IP address, normalize according to RCC 6066 ch. 3,