cvs: /php4 SAPI.c php.h php_virtual_cwd.c

From: Date: Sun, 02 Apr 2000 19:05:30 +0000
Subject: cvs: /php4 SAPI.c php.h php_virtual_cwd.c
Groups: php.version4 
Request: Send a blank email to php-version4+get-13012@lists.php.net to get a copy of this message
andi Sun Apr 2 12:05:30 2000 EDT Modified files: /php4 SAPI.c php.h php_virtual_cwd.c Log: - Virtual cwd compiles now (need to uncomment #define in php.h for it to be enbaled right now). It seems to work very basic stuff Index: php4/SAPI.c diff -u php4/SAPI.c:1.69 php4/SAPI.c:1.70 --- php4/SAPI.c:1.69 Fri Mar 31 17:11:39 2000 +++ php4/SAPI.c Sun Apr 2 12:04:59 2000 @@ -80,6 +80,10 @@ sapi_globals_ctor(&sapi_globals); #endif +#ifdef VIRTUAL_DIR + virtual_cwd_startup(); /* Could use shutdown to free the main cwd but it would just slow it down for CGI */ +#endif + reentrancy_startup(); php_global_startup_internal_extensions(); Index: php4/php.h diff -u php4/php.h:1.74 php4/php.h:1.75 --- php4/php.h:1.74 Thu Mar 30 14:56:30 2000 +++ php4/php.h Sun Apr 2 12:04:59 2000 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php.h,v 1.74 2000/03/30 22:56:30 andi Exp $ */ +/* $Id: php.h,v 1.75 2000/04/02 19:04:59 andi Exp $ */ #ifndef _PHP_H #define _PHP_H @@ -284,8 +284,10 @@ #define PUTS_H(str) php_header_write((str), strlen((str))) #define PUTC_H(c) (php_header_write(&(c), 1), (c)) +/* #define VIRTUAL_DIR */ /* Virtual current directory support */ #ifdef VIRTUAL_DIR +#include "php_virtual_cwd.h" #define PHP_GETCWD(buff, size) virtual_getcwd(buff,size) #define PHP_FOPEN(path, mode) virtual_fopen(path, mode) #define PHP_CHDIR(path) virtual_chdir(path) Index: php4/php_virtual_cwd.c diff -u php4/php_virtual_cwd.c:1.20 php4/php_virtual_cwd.c:1.21 --- php4/php_virtual_cwd.c:1.20 Sat Apr 1 12:11:01 2000 +++ php4/php_virtual_cwd.c Sun Apr 2 12:04:59 2000 @@ -258,7 +258,7 @@ ptr = strtok_r(NULL, TOKENIZER_STRING, &tok); } - if (verify_path && !verify_path(state)) { + if (verify_path && verify_path(state)) { free(state->cwd); *state = *old_state;

« previous php.version4 (#13012) next »