]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
PR#742: mod_include was not properly changing directory
authordgaudet <dgaudet@unknown>
Sat, 28 Jun 1997 19:50:15 +0000 (19:50 +0000)
committerdgaudet <dgaudet@unknown>
Sat, 28 Jun 1997 19:50:15 +0000 (19:50 +0000)
Reviewed by: Dean, Brian
Submitted by: Marc
Obtained from:

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/1.3@78399 13f79535-47bb-0310-9956-ffa450edef68

APACHE_1_2_X/src/modules/standard/mod_include.c

index 45157eff43ce7779a8f1e2e875f5301027a3bc16..d38694cd30a30d43a111caa724c1d1e8cae2fdfb 100644 (file)
@@ -520,6 +520,7 @@ int include_cgi(char *s, request_rec *r)
     }
     
     destroy_sub_req (rr);
+    chdir_file(r->filename);
     
     return 0;
 }
@@ -567,6 +568,7 @@ int handle_include(FILE *in, request_rec *r, char *error, int noexec) {
            
            if (!error_fmt && run_sub_req (rr))
                error_fmt = "unable to include %s in parsed file %s";
+           chdir_file(r->filename);
                    
             if (error_fmt) {
                 log_printf(r->server, error_fmt, tag_val, r->filename);