]> granicus.if.org Git - php/commitdiff
MFH: don't leak when decoding failed
authorAntony Dovgal <tony2001@php.net>
Tue, 6 Jun 2006 14:09:12 +0000 (14:09 +0000)
committerAntony Dovgal <tony2001@php.net>
Tue, 6 Jun 2006 14:09:12 +0000 (14:09 +0000)
main/streams/memory.c

index cda930fe2f83c9761189af49968bda7ebd5bfeba..0fcc165730be7a8a391b921803fe11520c35175f 100644 (file)
@@ -661,6 +661,7 @@ static php_stream * php_stream_url_wrap_rfc2397(php_stream_wrapper *wrapper, cha
        if (base64) {
                comma = (char*)php_base64_decode((const unsigned char *)comma, dlen, &ilen);
                if (!comma) {
+                       zval_ptr_dtor(&meta);
                        php_stream_wrapper_log_error(wrapper, options TSRMLS_CC, "rfc2397: unable to decode");
                        return NULL;
                }