cvs: php4 /main SAPI.c php.h

From: Date: Mon, 04 Sep 2000 04:18:04 +0000
Subject: cvs: php4 /main SAPI.c php.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-1538@lists.php.net to get a copy of this message
andi Sun Sep 3 21:18:04 2000 EDT Modified files: /php4/main SAPI.c php.h Log: - Found my bug and managed to move the V_* macros to TSRM Index: php4/main/SAPI.c diff -u php4/main/SAPI.c:1.85 php4/main/SAPI.c:1.86 --- php4/main/SAPI.c:1.85 Sun Aug 27 02:48:03 2000 +++ php4/main/SAPI.c Sun Sep 3 21:18:04 2000 @@ -85,7 +85,7 @@ sapi_globals_ctor(&sapi_globals); #endif -#ifdef VIRTUAL_DIR +#ifdef ZTS virtual_cwd_startup(); /* Could use shutdown to free the main cwd but it would just slow it down for CGI */ #endif @@ -97,7 +97,7 @@ SAPI_API void sapi_shutdown(void) { reentrancy_shutdown(); -#ifdef VIRTUAL_DIR +#ifdef ZTS virtual_cwd_shutdown(); #endif php_global_shutdown_internal_extensions(); Index: php4/main/php.h diff -u php4/main/php.h:1.123 php4/main/php.h:1.124 --- php4/main/php.h:1.123 Sun Sep 3 11:45:02 2000 +++ php4/main/php.h Sun Sep 3 21:18:04 2000 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php.h,v 1.123 2000/09/03 18:45:02 andi Exp $ */ +/* $Id: php.h,v 1.124 2000/09/04 04:18:04 andi Exp $ */ #ifndef PHP_H #define PHP_H @@ -290,65 +290,8 @@ #define VIRTUAL_DIR #endif +/* Virtual current working directory support */ #include "tsrm_virtual_cwd.h" - -/* Virtual current directory support */ -#ifdef VIRTUAL_DIR - -#define V_GETCWD(buff, size) virtual_getcwd(buff,size) -#define V_FOPEN(path, mode) virtual_fopen(path, mode) -/* The V_OPEN macro will need to be used as V_OPEN((path, flags, ...)) */ -#define V_OPEN(open_args) virtual_open open_args -#define V_CREAT(path, mode) virtual_creat(path, mode) -#define V_CHDIR(path) virtual_chdir(path) -#define V_CHDIR_FILE(path) virtual_chdir_file(path, virtual_chdir) -#define V_GETWD(buf) -#define V_REALPATH(path,real_path) virtual_realpath(path,real_path) -#define V_STAT(path, buff) virtual_stat(path, buff) -#ifdef PHP_WIN32 -#define V_LSTAT(path, buff) virtual_stat(path, buff) -#else -#define V_LSTAT(path, buff) virtual_lstat(path, buff) -#endif -#define V_UNLINK(path) virtual_unlink(path) -#define V_MKDIR(pathname, mode) virtual_mkdir(pathname, mode) -#define V_RMDIR(pathname) virtual_rmdir(pathname) -#define V_OPENDIR(pathname) virtual_opendir(pathname) -#define V_POPEN(command, type) virtual_popen(command, type) -#if HAVE_UTIME -#define V_UTIME(path,time) virtual_utime(path,time) -#endif -#define V_CHMOD(path,mode) virtual_chmod(path,mode) -#ifndef PHP_WIN32 -#define V_CHOWN(path,owner,group) virtual_chown(path,owner,group) -#endif - -#else /* !defined(VIRTUAL_DIR) */ - -#define V_GETCWD(buff, size) getcwd(buff,size) -#define V_FOPEN(path, mode) fopen(path, mode) -#define V_OPEN(open_args) open open_args -#define V_CREAT(path, mode) creat(path, mode) -#define V_CHDIR(path) chdir(path) -#define V_CHDIR_FILE(path) virtual_chdir_file(path, chdir) -#define V_GETWD(buf) getwd(buf) -#define V_STAT(path, buff) stat(path, buff) -#define V_LSTAT(path, buff) lstat(path, buff) -#define V_UNLINK(path) unlink(path) -#define V_MKDIR(pathname, mode) mkdir(pathname, mode) -#define V_RMDIR(pathname) rmdir(pathname) -#define V_OPENDIR(pathname) opendir(pathname) -#define V_POPEN(command, type) popen(command, type) -#define V_REALPATH(path,real_path) realpath(path,real_path) -#if HAVE_UTIME -#define V_UTIME(path,time) utime(path,time) -#endif -#define V_CHMOD(path,mode) chmod(path,mode) -#ifndef PHP_WIN32 -#define V_CHOWN(path,owner,group) chown(path,owner,group) -#endif - -#endif /* VIRTUAL_DIR */ #include "zend_constants.h"

« previous php.cvs (#1538) next »