cvs: php4 /main fopen_wrappers.c
| From: | Zeev Suraski | Date: | Mon, 16 Jul 2001 13:31:55 +0000 |
| Subject: | cvs: php4 /main fopen_wrappers.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-6242@lists.php.net to get a copy of this message | ||
zeev Mon Jul 16 09:31:55 2001 EDT
Modified files:
/php4/main fopen_wrappers.c
Log:
Generalize
Index: php4/main/fopen_wrappers.c
diff -u php4/main/fopen_wrappers.c:1.123 php4/main/fopen_wrappers.c:1.124
--- php4/main/fopen_wrappers.c:1.123 Sun Jul 15 08:24:06 2001
+++ php4/main/fopen_wrappers.c Mon Jul 16 09:31:55 2001
@@ -16,7 +16,7 @@
| Jim Winstead <jimw@php.net> |
+----------------------------------------------------------------------+
*/
-/* $Id: fopen_wrappers.c,v 1.123 2001/07/15 12:24:06 zeev Exp $ */
+/* $Id: fopen_wrappers.c,v 1.124 2001/07/16 13:31:55 zeev Exp $ */
/* {{{ includes
*/
@@ -215,11 +215,7 @@
ptr = pathbuf;
while (ptr && *ptr) {
-#ifdef PHP_WIN32
- end = strchr(ptr, ';');
-#else
- end = strchr(ptr, ':');
-#endif
+ end = strchr(ptr, DEFAULT_DIR_SEPARATOR);
if (end != NULL) {
*end = '\0';
end++;
@@ -478,11 +474,7 @@
pathbuf = (char *) emalloc(exec_fname_length + path_length +1 +1);
memcpy(pathbuf, path, path_length);
-#ifdef PHP_WIN32
- pathbuf[path_length] = ';';
-#else
- pathbuf[path_length] = ':';
-#endif
+ pathbuf[path_length] = DEFAULT_DIR_SEPARATOR;
memcpy(pathbuf+path_length+1, exec_fname, exec_fname_length);
pathbuf[path_length + exec_fname_length +1] = '\0';
} else {
@@ -492,11 +484,7 @@
ptr = pathbuf;
while (ptr && *ptr) {
-#ifdef PHP_WIN32
- end = strchr(ptr, ';');
-#else
- end = strchr(ptr, ':');
-#endif
+ end = strchr(ptr, DEFAULT_DIR_SEPARATOR);
if (end != NULL) {
*end = '\0';
end++;