Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit deecaa2

Browse files
committed
openssl: free the context even if we don't connect
1 parent bf127ee commit deecaa2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/openssl_stream.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,6 @@ static int ssl_teardown(SSL *ssl)
267267
else
268268
ret = 0;
269269

270-
SSL_free(ssl);
271270
return ret;
272271
}
273272

@@ -530,6 +529,7 @@ void openssl_free(git_stream *stream)
530529
{
531530
openssl_stream *st = (openssl_stream *) stream;
532531

532+
SSL_free(st->ssl);
533533
git__free(st->host);
534534
git__free(st->cert_info.data);
535535
git_stream_free(st->io);

0 commit comments

Comments
 (0)