summaryrefslogtreecommitdiff
path: root/cgi_main.c
diff options
context:
space:
mode:
authorZeev Suraski <zeev@php.net>1999-05-02 19:54:02 +0000
committerZeev Suraski <zeev@php.net>1999-05-02 19:54:02 +0000
commita5ab6b9638c76748f7b9b66ebbd4d8cacf682250 (patch)
tree68c045f85fd7ea5fd8c20d2d460180392352be31 /cgi_main.c
parent7071131f81c53b5ff062f724a0aa758a5138e012 (diff)
downloadphp-git-a5ab6b9638c76748f7b9b66ebbd4d8cacf682250.tar.gz
Move path_info to the SAPI structure
Diffstat (limited to 'cgi_main.c')
-rw-r--r--cgi_main.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/cgi_main.c b/cgi_main.c
index 2fe4e50ecd..792e2fe9c6 100644
--- a/cgi_main.c
+++ b/cgi_main.c
@@ -115,6 +115,13 @@ static void php_cgi_usage(char *argv0)
}
+static void init_request_info(SLS_D)
+{
+ SG(request_info).query_string = getenv("QUERY_STRING");
+ SG(request_info).request_uri = getenv("PATH_INFO");
+}
+
+
int main(int argc, char *argv[])
{
int cgi = 0, c, i, len;
@@ -293,7 +300,7 @@ any .htaccess restrictions anywhere on your site you can leave doc_root undefine
php3_TreatHeaders();
- SG(request_info).query_string = getenv("QUERY_STRING");
+ init_request_info(SLS_C);
if (!cgi) {
if (!SG(request_info).query_string) {