]> granicus.if.org Git - php/commitdiff
fix unfreed value found in tempmanifest1.phpt
authorGreg Beaver <cellog@php.net>
Sat, 23 Feb 2008 19:44:51 +0000 (19:44 +0000)
committerGreg Beaver <cellog@php.net>
Sat, 23 Feb 2008 19:44:51 +0000 (19:44 +0000)
ext/phar/phar.c

index 481974da3f1b916425731251946631822e350764..1707259be52a81c1a5b629f145d8bd9f9940e2c3 100644 (file)
@@ -2573,6 +2573,9 @@ int phar_zend_open(const char *filename, zend_file_handle *handle TSRMLS_DC) /*
                                                /* this file is not in the phar, use the original path */
                                                if (SUCCESS == phar_orig_zend_open(filename, handle TSRMLS_CC)) {
                                                        if (SUCCESS == phar_mount_entry(*pphar, handle->opened_path ? handle->opened_path : (char *) filename, strlen(handle->opened_path ? handle->opened_path : filename), (char *) filename, strlen(filename) TSRMLS_CC)) {
+                                                               if (handle->opened_path) {
+                                                                       efree(handle->opened_path);
+                                                               }
                                                                entry = (char *) filename;
                                                                goto dopharthing;
                                                        }