cvs: php-src /sapi/apache2handler php_functions.c

From: Date: Sun, 01 Jan 2006 20:13:31 +0000
Subject: cvs: php-src /sapi/apache2handler php_functions.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-36356@lists.php.net to get a copy of this message
iliaa Sun Jan 1 20:13:31 2006 UTC Modified files: /php-src/sapi/apache2handler php_functions.c Log: MFB51: Added safety checks http://cvs.php.net/viewcvs.cgi/php-src/sapi/apache2handler/php_functions.c?r1=1.20&r2=1.21&diff_format=u Index: php-src/sapi/apache2handler/php_functions.c diff -u php-src/sapi/apache2handler/php_functions.c:1.20 php-src/sapi/apache2handler/php_functions.c:1.21 --- php-src/sapi/apache2handler/php_functions.c:1.20 Sun Jan 1 13:09:57 2006 +++ php-src/sapi/apache2handler/php_functions.c Sun Jan 1 20:13:31 2006 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_functions.c,v 1.20 2006/01/01 13:09:57 sniper Exp $ */ +/* $Id: php_functions.c,v 1.21 2006/01/01 20:13:31 iliaa Exp $ */ #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS @@ -58,13 +58,11 @@ static request_rec *php_apache_lookup_uri(char *filename TSRMLS_DC) { - php_struct *ctx; + php_struct *ctx = SG(server_context); - if (!filename) { + if (!filename || !ctx || !ctx->r) { return NULL; } - - ctx = SG(server_context); return ap_sub_req_lookup_uri(filename, ctx->r, ctx->r->output_filters); }

« previous php.cvs (#36356) next »