ssb Sun Apr 8 14:57:14 2001 EDT
Modified files:
/php4/ext/standard dir.c
Log:
@Add DIRECTORY_SEPARATOR constant ('/' on UNIX, '\' on Windows) (Stig)
Index: php4/ext/standard/dir.c
diff -u php4/ext/standard/dir.c:1.58 php4/ext/standard/dir.c:1.59
--- php4/ext/standard/dir.c:1.58 Sun Feb 25 22:07:17 2001
+++ php4/ext/standard/dir.c Sun Apr 8 14:57:13 2001
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: dir.c,v 1.58 2001/02/26 06:07:17 andi Exp $ */
+/* $Id: dir.c,v 1.59 2001/04/08 21:57:13 ssb Exp $ */
/* {{{ includes/startup/misc */
@@ -128,6 +128,7 @@
PHP_MINIT_FUNCTION(dir)
{
+ static char tmpstr[2];
zend_class_entry dir_class_entry;
le_dirp = zend_register_list_destructors_ex(_dir_dtor, NULL, "dir",
module_number);
@@ -138,6 +139,9 @@
#ifdef ZTS
dir_globals_id = ts_allocate_id(sizeof(php_dir_globals), NULL, NULL);
#endif
+ tmpstr[0] = DEFAULT_SLASH;
+ tmpstr[1] = '\0';
+ REGISTER_STRING_CONSTANT("DIRECTORY_SEPARATOR", tmpstr, 0);
return SUCCESS;
}
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]