Skip to content

Commit bf64f38

Browse files
committed
Fixing memory leak
1 parent d1670fb commit bf64f38

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

ext/openssl/openssl.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2169,6 +2169,7 @@ PHP_FUNCTION(openssl_x509_parse)
21692169
str_serial = i2s_ASN1_INTEGER(NULL, asn1_serial);
21702170
/* Can return NULL on error or memory allocation failure */
21712171
if (!str_serial) {
2172+
OPENSSL_free(hex_serial);
21722173
php_openssl_store_errors();
21732174
goto err;
21742175
}

0 commit comments

Comments
 (0)