cvs: php4 /sapi/cgi cgi_main.c
| From: | Andi Gutmans | Date: | Tue, 03 Oct 2000 13:02:30 +0000 |
| Subject: | cvs: php4 /sapi/cgi cgi_main.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-1919@lists.php.net to get a copy of this message | ||
andi Tue Oct 3 06:02:30 2000 EDT
Modified files:
/php4/sapi/cgi cgi_main.c
Log:
- Fix request_uri to take it's value from SCRIPT_NAME if PATH_INFO is not
defined
Index: php4/sapi/cgi/cgi_main.c
diff -u php4/sapi/cgi/cgi_main.c:1.70 php4/sapi/cgi/cgi_main.c:1.71
--- php4/sapi/cgi/cgi_main.c:1.70 Sat Sep 30 09:11:16 2000
+++ php4/sapi/cgi/cgi_main.c Tue Oct 3 06:02:30 2000
@@ -312,6 +312,9 @@
SG(request_info).request_method = getenv("REQUEST_METHOD");
SG(request_info).query_string = getenv("QUERY_STRING");
SG(request_info).request_uri = getenv("PATH_INFO");
+ if (!SG(request_info).request_uri) {
+ SG(request_info).request_uri = getenv("SCRIPT_NAME");
+ }
SG(request_info).path_translated = NULL; /* we have to update it later, when we have that
information */
SG(request_info).content_type = getenv("CONTENT_TYPE");
SG(request_info).content_length = (content_length?atoi(content_length):0);