Commit:    35f86d24d81b81e8c755e82d0b2e76d36f4a0201
Author:    Dmitry Stogov <dmi...@zend.com>         Thu, 13 Dec 2012 13:39:42 
+0400
Parents:   1f516510b77eade91e56de4f64183ea44d0cde0f
Branches:  PHP-5.4 PHP-5.5 master

Link:       
http://git.php.net/?p=php-src.git;a=commitdiff;h=35f86d24d81b81e8c755e82d0b2e76d36f4a0201

Log:
Fixed bug #63757 (getenv() produces memory leak with CGI SAPI)

Bugs:
https://bugs.php.net/63757

Changed paths:
  M  NEWS
  M  main/SAPI.c


Diff:
diff --git a/NEWS b/NEWS
index 0504472..dfbcbf0 100644
--- a/NEWS
+++ b/NEWS
@@ -2,6 +2,9 @@ PHP                                                             
           NEWS
 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
 ?? ??? 2012, PHP 5.4.11
 
+- Filter:
+  . Fixed bug #63757 (getenv() produces memory leak with CGI SAPI). (Dmitry)
+
 - JSON:
   . Fixed bug #63737 (json_decode does not properly decode with options
     parameter). (Adam)
diff --git a/main/SAPI.c b/main/SAPI.c
index fc4b7be..e72eafb 100644
--- a/main/SAPI.c
+++ b/main/SAPI.c
@@ -1017,7 +1017,7 @@ SAPI_API char *sapi_getenv(char *name, size_t name_len 
TSRMLS_DC)
                        return NULL;
                }
                if (sapi_module.input_filter) {
-                       sapi_module.input_filter(PARSE_ENV, name, &value, 
strlen(value), NULL TSRMLS_CC);
+                       sapi_module.input_filter(PARSE_STRING, name, &value, 
strlen(value), NULL TSRMLS_CC);
                }
                return value;
        }


--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to