From: Daniel Stenberg Date: Thu, 15 Apr 2021 15:46:24 +0000 (+0200) Subject: libssh2: fix Value stored to 'sshp' is never read X-Git-Tag: curl-7_77_0~188 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b532d35b5c97a2900f8511f3ecbf45c9342cfcba;p=thirdparty%2Fcurl.git libssh2: fix Value stored to 'sshp' is never read Pointed out by scan-build Closes #6900 --- diff --git a/lib/vssh/libssh2.c b/lib/vssh/libssh2.c index 9d188d0582..2d431ce347 100644 --- a/lib/vssh/libssh2.c +++ b/lib/vssh/libssh2.c @@ -3054,17 +3054,15 @@ static CURLcode ssh_connect(struct Curl_easy *data, bool *done) #ifdef CURL_LIBSSH2_DEBUG curl_socket_t sock; #endif - struct SSHPROTO *sshp = data->req.p.ssh; struct ssh_conn *sshc; CURLcode result; struct connectdata *conn = data->conn; /* initialize per-handle data if not already */ - if(!sshp) { + if(!data->req.p.ssh) { result = ssh_setup_connection(data, conn); if(result) return result; - sshp = data->req.p.ssh; } /* We default to persistent connections. We set this already in this connect