cvs: php4 /main fopen-wrappers.c main.c php.h

From: Date: Sun, 20 Aug 2000 19:56:24 +0000
Subject: cvs: php4 /main fopen-wrappers.c main.c php.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-1273@lists.php.net to get a copy of this message
andi Sun Aug 20 12:56:24 2000 EDT Modified files: /php4/main fopen-wrappers.c main.c php.h Log: - Change PHP_SEPARATOR to PHP_DIR_SEPARATOR Index: php4/main/fopen-wrappers.c diff -u php4/main/fopen-wrappers.c:1.79 php4/main/fopen-wrappers.c:1.80 --- php4/main/fopen-wrappers.c:1.79 Sun Aug 20 07:02:57 2000 +++ php4/main/fopen-wrappers.c Sun Aug 20 12:56:24 2000 @@ -16,7 +16,7 @@ | Jim Winstead <jimw@php.net> | +----------------------------------------------------------------------+ */ -/* $Id: fopen-wrappers.c,v 1.79 2000/08/20 14:02:57 sas Exp $ */ +/* $Id: fopen-wrappers.c,v 1.80 2000/08/20 19:56:24 andi Exp $ */ #include "php.h" #include "php_globals.h" @@ -317,8 +317,8 @@ if (pw && pw->pw_dir) { filename = emalloc(strlen(PG(user_dir)) + strlen(path_info) + strlen(pw->pw_dir) + 4); if (filename) { - sprintf(filename, "%s%c%s%c%s", pw->pw_dir, PHP_SEPARATOR, - PG(user_dir), PHP_SEPARATOR, s+1); /* Safe */ + sprintf(filename, "%s%c%s%c%s", pw->pw_dir, PHP_DIR_SEPARATOR, + PG(user_dir), PHP_DIR_SEPARATOR, s+1); /* Safe */ STR_FREE(SG(request_info).path_translated); SG(request_info).path_translated = filename; } @@ -338,7 +338,7 @@ if (filename) { memcpy(filename, PG(doc_root), length); if (!IS_SLASH(filename[length - 1])) { /* length is never 0 */ - filename[length++] = PHP_SEPARATOR; + filename[length++] = PHP_DIR_SEPARATOR; } if (IS_SLASH(path_info[0])) { length--; Index: php4/main/main.c diff -u php4/main/main.c:1.295 php4/main/main.c:1.296 --- php4/main/main.c:1.295 Sun Aug 20 11:12:16 2000 +++ php4/main/main.c Sun Aug 20 12:56:24 2000 @@ -19,7 +19,7 @@ */ -/* $Id: main.c,v 1.295 2000/08/20 18:12:16 andi Exp $ */ +/* $Id: main.c,v 1.296 2000/08/20 19:56:24 andi Exp $ */ #include <stdio.h> @@ -1148,7 +1148,7 @@ && primary_file->filename) { char *filename; - filename = strrchr(primary_file->filename, PHP_SEPARATOR); + filename = strrchr(primary_file->filename, PHP_DIR_SEPARATOR); if (filename) { filename++; Index: php4/main/php.h diff -u php4/main/php.h:1.113 php4/main/php.h:1.114 --- php4/main/php.h:1.113 Sun Aug 20 07:02:57 2000 +++ php4/main/php.h Sun Aug 20 12:56:24 2000 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php.h,v 1.113 2000/08/20 14:02:57 sas Exp $ */ +/* $Id: php.h,v 1.114 2000/08/20 19:56:24 andi Exp $ */ #ifndef PHP_H #define PHP_H @@ -65,11 +65,11 @@ # else # define PHPAPI __declspec(dllimport) # endif -#define PHP_SEPARATOR '\\' +#define PHP_DIR_SEPARATOR '\\' #else #define PHPAPI #define THREAD_LS -#define PHP_SEPARATOR '/' +#define PHP_DIR_SEPARATOR '/' #endif #include "php_regex.h"

« previous php.cvs (#1273) next »