diff options
author | Gisle Vanem <gvanem@broadpark.no> | 2006-11-15 05:35:35 +0000 |
---|---|---|
committer | Gisle Vanem <gvanem@broadpark.no> | 2006-11-15 05:35:35 +0000 |
commit | b8039a821b0f5b8c889c5ec0d9027d23581b336b (patch) | |
tree | c4d3203ebf0388b204f8f3e0d4b9507f922511af | |
parent | 438312f00e3813efe576a2d5d78844b5451b1f69 (diff) |
Call libssh2_session_free() to release memory allocated during
libssh2 startup.
-rw-r--r-- | lib/ssh.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -303,6 +303,7 @@ CURLcode Curl_scp_connect(struct connectdata *conn, bool *done) if (libssh2_session_startup(scp->scpSession, sock)) { failf(data, "Failure establishing ssh session\n"); + libssh2_session_free(scp->scpSession); Curl_safefree(scp->path); return CURLE_FAILED_INIT; } @@ -395,6 +396,7 @@ CURLcode Curl_scp_connect(struct connectdata *conn, bool *done) if (!authed) { failf(data, "Authentication failure\n"); + libssh2_session_free(scp->scpSession); Curl_safefree(scp->path); return CURLE_FAILED_INIT; } |