com php-src: Fix memory leak when compiling files in phpdbg: sapi/phpdbg/phpdbg_list.c

From: Date: Fri, 14 Oct 2016 10:24:28 +0000
Subject: com php-src: Fix memory leak when compiling files in phpdbg: sapi/phpdbg/phpdbg_list.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-95085@lists.php.net to get a copy of this message
Commit: 466870e2b07be801faa8e0ccf81aff0455932b45 Author: Bob Weinand <bobwei9@hotmail.com> Fri, 14 Oct 2016 12:24:28 +0200 Parents: 428ef5083819328b40357e1de229d5cf740a36e7 Branches: PHP-7.0 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=466870e2b07be801faa8e0ccf81aff0455932b45 Log: Fix memory leak when compiling files in phpdbg Changed paths: M sapi/phpdbg/phpdbg_list.c Diff: diff --git a/sapi/phpdbg/phpdbg_list.c b/sapi/phpdbg/phpdbg_list.c index 8759461..b0bb157 100644 --- a/sapi/phpdbg/phpdbg_list.c +++ b/sapi/phpdbg/phpdbg_list.c @@ -312,8 +312,8 @@ zend_op_array *phpdbg_init_compile_file(zend_file_handle *file, int type) { if (file->free_filename) { efree((char *) file->filename); } - file->free_filename = 1; - file->filename = estrdup(filename); + file->free_filename = 0; + file->filename = filename; } }

« previous php.cvs (#95085) next »