summaryrefslogtreecommitdiff
path: root/sapi
diff options
context:
space:
mode:
authorAntony Dovgal <tony2001@php.net>2007-04-17 18:51:34 +0000
committerAntony Dovgal <tony2001@php.net>2007-04-17 18:51:34 +0000
commit44066f23b7c5a14a74f04ecfc723acea7e9504c8 (patch)
tree59f3208881295d4bc71d1fba55462f1ace9ea61f /sapi
parent9ab23a7e53d5efc1417a8b71acff8666fe6b31a0 (diff)
downloadphp-git-44066f23b7c5a14a74f04ecfc723acea7e9504c8.tar.gz
MFH: fix leak appearing when more than one -f option specified
Diffstat (limited to 'sapi')
-rw-r--r--sapi/cgi/cgi_main.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c
index e8f277cfc3..4b76954568 100644
--- a/sapi/cgi/cgi_main.c
+++ b/sapi/cgi/cgi_main.c
@@ -1478,6 +1478,9 @@ consult the installation file that came with this distribution, or visit \n\
break;
case 'f': /* parse file */
+ if (script_file) {
+ efree(script_file);
+ }
script_file = estrdup(php_optarg);
no_headers = 1;
/* arguments after the file are considered script args */