Re: [PHP-CVS] cvs: php4 / README.TESTING
At 01:26 24-10-2002, Marcus Börger wrote: Shouldn't we allow - in %i, too? I would like the following: %i = [+\-]?[0-9]+ %d = [0-9]+ %f = [+\-]?\.?[0-9]+\.?[0-9]* +1 on that. Met vriendelijke groeten / With kind regards, Webmaster IDG.nl Melvyn Sopacua -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php4 /main rfc1867.c
On Thu, Oct 24, 2002 at 03:47:21PM +0900, Moriyoshi Koizumi wrote : This commit occurred on the HEAD branch. Was it intended for some other branch or is the log message incorrect? Neither, though I don't know what you really mean. My previous patch to main/rfc1867.c was wrong, so I've corrected it. Is something going wrong with that? He meant your log message: MFH; we would see a nasty problem again if it was not fixed... MFH means Merge from HEAD and thus it surely puzzles people if you actually apply it to HEAD and not to a branch. -- GnuPG Key: http://guru.josefine.at/~mfischer/C2272BD0.asc $ grep docref_root php.ini docref_root = http://landonize.it/?how=urltheme=classicfilter=RichyHuser=imajesurl=http%3A%2F%2Fphp.net%2F/; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php4 /main rfc1867.c
Oooh, sorry for the confusion, I've ever misused it. Thank you for letting me know. I'll use as accurate words as possible from now on and please notify me if you find my abuse of words :) Moriyoshi Markus Fischer [EMAIL PROTECTED] wrote: On Thu, Oct 24, 2002 at 03:47:21PM +0900, Moriyoshi Koizumi wrote : This commit occurred on the HEAD branch. Was it intended for some other branch or is the log message incorrect? Neither, though I don't know what you really mean. My previous patch to main/rfc1867.c was wrong, so I've corrected it. Is something going wrong with that? He meant your log message: MFH; we would see a nasty problem again if it was not fixed... MFH means Merge from HEAD and thus it surely puzzles people if you actually apply it to HEAD and not to a branch. -- GnuPG Key: http://guru.josefine.at/~mfischer/C2272BD0.asc $ grep docref_root php.ini docref_root = http://landonize.it/?how=urltheme=classicfilter=RichyHuser=imajesurl=http%3A%2F%2Fphp.net%2F/; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/standard exec.c
jan Thu Oct 24 04:46:22 2002 EDT Modified files: /php4/ext/standard exec.c Log: - fix segfault in proc_open #no bugreports found Index: php4/ext/standard/exec.c diff -u php4/ext/standard/exec.c:1.82 php4/ext/standard/exec.c:1.83 --- php4/ext/standard/exec.c:1.82 Wed Sep 25 11:46:46 2002 +++ php4/ext/standard/exec.cThu Oct 24 04:46:21 2002 -15,7 +15,7 | Author: Rasmus Lerdorf | +--+ */ -/* $Id: exec.c,v 1.82 2002/09/25 15:46:46 wez Exp $ */ +/* $Id: exec.c,v 1.83 2002/10/24 08:46:21 jan Exp $ */ #include stdio.h #include php.h -761,7 +761,7 if (zend_hash_index_find(Z_ARRVAL_PP(descitem), 0, (void **)ztype) == SUCCESS) { convert_to_string_ex(ztype); } else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, Missing handle qualifier in array, Z_STRVAL_PP(ztype)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, Missing +handle qualifier in array); goto exit_fail; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/ftp ftp.c
hyanantha Thu Oct 24 05:48:07 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/ftp ftp.c Log: NetWare related changes/modifications. Index: php4/ext/ftp/ftp.c diff -u php4/ext/ftp/ftp.c:1.44.2.2 php4/ext/ftp/ftp.c:1.44.2.3 --- php4/ext/ftp/ftp.c:1.44.2.2 Mon Mar 18 18:16:57 2002 +++ php4/ext/ftp/ftp.c Thu Oct 24 05:48:07 2002 -16,7 +16,7 +--+ */ -/* $Id: ftp.c,v 1.44.2.2 2002/03/18 23:16:57 vlad Exp $ */ +/* $Id: ftp.c,v 1.44.2.3 2002/10/24 09:48:07 hyanantha Exp $ */ #include php.h -33,6 +33,18 #include time.h #ifdef PHP_WIN32 #include winsock.h +#elif defined(NETWARE) +#ifdef USE_WINSOCK/* Modified to use Winsock (NOVSOCK2.H), atleast for now */ +#include novsock2.h +#else +#ifdef NEW_LIBC +#include sys/socket.h +#include netinet/in.h +#include netdb.h +#else +#include sys/socket.h +#endif +#endif #else #ifdef HAVE_SYS_TYPES_H #include sys/types.h -56,11 +68,16 #include ext/standard/fsock.h /* define closesocket macro for portability */ -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !(defined(NETWARE) defined(USE_WINSOCK)) #undef closesocket #define closesocket close #endif +/* Additional headers for NetWare */ +#if defined(NETWARE) defined(NEW_LIBC) !defined(USE_WINSOCK) +#include sys/select.h +#endif + /* sends an ftp command, returns true on success, false on error. * it sends the string cmd args\r\n if args is non-null, or * cmd\r\n if args is null -130,7 +147,7 size = sizeof(ftp-localaddr); memset(ftp-localaddr, 0, size); - if (getsockname(ftp-fd, (struct sockaddr*) ftp-localaddr, size) == -1) { + if (getsockname(ftp-fd, (struct sockaddr*) ftp-localaddr, (unsigned +int*)size) == -1) { perror(getsockname); goto bail; } -946,7 +963,7 FD_SET(s, write_set); n = select(s + 1, NULL, write_set, NULL, tv); if (n 1) { -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !(defined(NETWARE) defined(USE_WINSOCK)) if (n == 0) errno = ETIMEDOUT; #endif -981,7 +998,7 FD_SET(s, read_set); n = select(s + 1, read_set, NULL, NULL, tv); if (n 1) { -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !(defined(NETWARE) defined(USE_WINSOCK)) if (n == 0) errno = ETIMEDOUT; #endif -1008,14 +1025,14 n = select(s + 1, accept_set, NULL, NULL, tv); if (n 1) { -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !(defined(NETWARE) defined(USE_WINSOCK)) if (n == 0) errno = ETIMEDOUT; #endif return -1; } - return accept(s, addr, addrlen); + return accept(s, addr, (unsigned int*)addrlen); } /* }}} */ -1087,7 +1104,7 goto bail; } - if (getsockname(fd, (struct sockaddr*) addr, size) == -1) { + if (getsockname(fd, (struct sockaddr*) addr, (unsigned int*)size) == -1) { perror(getsockname); goto bail; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/ftp php_ftp.c
hyanantha Thu Oct 24 05:48:40 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/ftp php_ftp.c Log: NetWare related changes/modifications. Index: php4/ext/ftp/php_ftp.c diff -u php4/ext/ftp/php_ftp.c:1.53.2.1 php4/ext/ftp/php_ftp.c:1.53.2.2 --- php4/ext/ftp/php_ftp.c:1.53.2.1 Fri Mar 29 20:58:24 2002 +++ php4/ext/ftp/php_ftp.c Thu Oct 24 05:48:40 2002 -16,7 +16,7 +--+ */ -/* $Id: php_ftp.c,v 1.53.2.1 2002/03/30 01:58:24 mfischer Exp $ */ +/* $Id: php_ftp.c,v 1.53.2.2 2002/10/24 09:48:40 hyanantha Exp $ */ #ifdef HAVE_CONFIG_H #include config.h -24,6 +24,16 #include php.h +#ifdef NETWARE +#ifdef USE_WINSOCK +#include novsock2.h +#else +#ifndef NEW_LIBC +#include sys/socket.h +#endif +#endif +#endif + #if HAVE_FTP #include ext/standard/info.h -482,7 +492,7 RETURN_FALSE; } -#ifdef PHP_WIN32 +#if defined(PHP_WIN32) || defined(NETWARE) /* On Windows and NetWare, the file +should always be opened in binary mode */ if ((outfp = VCWD_FOPEN(local, wb)) == NULL) { #else if ((outfp = VCWD_FOPEN(local, w)) == NULL) { -557,7 +567,7 ZEND_FETCH_RESOURCE(ftp, ftpbuf_t*, z_ftp, -1, le_ftpbuf_name, le_ftpbuf); XTYPE(xtype, mode); -#ifdef PHP_WIN32 +#if defined(PHP_WIN32) || defined(NETWARE) /* On Windows and NetWare, the file +should always be opened in binary mode */ if ((infp = VCWD_FOPEN(local, rb)) == NULL) { #else if ((infp = VCWD_FOPEN(local, r)) == NULL) { -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/imap php_imap.c
hyanantha Thu Oct 24 05:50:36 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/imap php_imap.c Log: NetWare related changes/modifications. Index: php4/ext/imap/php_imap.c diff -u php4/ext/imap/php_imap.c:1.112.2.8 php4/ext/imap/php_imap.c:1.112.2.9 --- php4/ext/imap/php_imap.c:1.112.2.8 Thu Sep 19 12:59:11 2002 +++ php4/ext/imap/php_imap.cThu Oct 24 05:50:36 2002 @@ -25,7 +25,7 @@ | PHP 4.0 updates: Zeev Suraski [EMAIL PROTECTED] | +--+ */ -/* $Id: php_imap.c,v 1.112.2.8 2002/09/19 16:59:11 derick Exp $ */ +/* $Id: php_imap.c,v 1.112.2.9 2002/10/24 09:50:36 hyanantha Exp $ */ #define IMAP41 @@ -421,7 +421,7 @@ ZEND_INIT_MODULE_GLOBALS(imap, php_imap_init_globals, NULL) -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) mail_link(unixdriver); /* link in the unix driver */ mail_link(mhdriver); /* link in the mh driver */ /* mail_link(mxdriver); */ /* According to c-client docs (internal.txt) this shouldn't be used. */ @@ -437,7 +437,7 @@ mail_link(mtxdriver); /* link in the mtx driver */ mail_link(dummydriver);/* link in the dummy driver */ -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) auth_link(auth_log); /* link in the log authenticator */ auth_link(auth_md5); /* link in the cram-md5 authenticator */ #ifdef HAVE_IMAP_SSL -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/imap imap.mak
hyanantha Thu Oct 24 05:51:40 2002 EDT Added files: (Branch: PHP_4_2_0) /php4/ext/imap imap.mak Log: NetWare related file. Index: php4/ext/imap/imap.mak +++ php4/ext/imap/imap.mak -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/ldap ldap.c
hyanantha Thu Oct 24 05:53:01 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/ldap ldap.c Log: NetWare related changes/modifications. Index: php4/ext/ldap/ldap.c diff -u php4/ext/ldap/ldap.c:1.116.2.2 php4/ext/ldap/ldap.c:1.116.2.3 --- php4/ext/ldap/ldap.c:1.116.2.2 Mon Sep 23 19:22:08 2002 +++ php4/ext/ldap/ldap.cThu Oct 24 05:53:01 2002 -22,13 +22,19 +--+ */ -/* $Id: ldap.c,v 1.116.2.2 2002/09/23 23:22:08 sniper Exp $ */ +/* $Id: ldap.c,v 1.116.2.3 2002/10/24 09:53:01 hyanantha Exp $ */ #define IS_EXT_MODULE #ifdef HAVE_CONFIG_H #include config.h #endif +/* Additional headers for NetWare */ +#if defined(NETWARE) (NEW_LIBC) +#include sys/select.h +#include sys/timeval.h +#endif + #include php.h #include php_ini.h -118,9 +124,11 PHP_FE(ldap_rename, NULL) #endif +#ifndef NETWARE/* The below function not supported on NetWare */ #if LDAP_API_VERSION 2000 PHP_FE(ldap_start_tls, NULL) #endif +#endif /* NETWARE */ #if defined(LDAP_API_FEATURE_X_OPENLDAP) defined(HAVE_3ARG_SETREBINDPROC) PHP_FE(ldap_set_rebind_proc,NULL) -263,7 +271,7 php_info_print_table_start(); php_info_print_table_row(2, LDAP Support, enabled ); - php_info_print_table_row(2, RCS Version, $Id: ldap.c,v 1.116.2.2 2002/09/23 23:22:08 sniper Exp $ ); + php_info_print_table_row(2, RCS Version, $Id: ldap.c,v 1.116.2.3 2002/10/24 +09:53:01 hyanantha Exp $ ); if (LDAPG(max_links) == -1) { snprintf(tmp, 31, %ld/unlimited, LDAPG(num_links)); -492,7 +500,16 ZEND_FETCH_RESOURCE(ld, ldap_linkdata *, link, -1, ldap link, le_link); +#ifndef NETWARE if (ldap_bind_s(ld-link, ldap_bind_rdn, ldap_bind_pw, LDAP_AUTH_SIMPLE) != LDAP_SUCCESS) { +#else + /* The function ldap_bind_s has been deprecated on NetWare. If it is used +on NetWare, + it gives the result, but will also result in the display of warning +message + that gets displayed on the web browser. + ldap_simple_bind_s removes that warning. + */ + if (ldap_simple_bind_s(ld-link, (const char *)ldap_bind_rdn, (const char +*)ldap_bind_pw) != LDAP_SUCCESS) { +#endif php_error(E_WARNING, LDAP: Unable to bind to server: %s, ldap_err2string(_get_lderrno(ld-link))); RETURN_FALSE; } else { -1992,6 +2009,7 /* }}} */ #endif +#ifndef NETWARE/* The below function not supported on NetWare */ #if LDAP_API_VERSION 2000 /* {{{ proto bool ldap_start_tls(resource link) Start TLS */ -2016,6 +2034,7 } /* }}} */ #endif +#endif /* NETWARE */ #if defined(LDAP_API_FEATURE_X_OPENLDAP) defined(HAVE_3ARG_SETREBINDPROC) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/mysql mysql.mak
hyanantha Thu Oct 24 05:54:45 2002 EDT Added files: (Branch: PHP_4_2_0) /php4/ext/mysql mysql.mak Log: NetWare related file. Index: php4/ext/mysql/mysql.mak +++ php4/ext/mysql/mysql.mak # Temporarily here -- later may go into some batch file # which will set this as an environment variable PROJECT_ROOT = ..\.. # Module details MODULE_NAME = phpmysql MODULE_DESC = PHP MySQL Extension VMAJ = 0 VMIN = 60 VREV = 0 #include the common settings include $(PROJECT_ROOT)/netware/common.mif # MYSQL stuff MYSQL_DIR = P:/APPS/script/sw/mysql # Build type defaults to 'release' ifndef BUILD BUILD = release endif # Extensions of all input and output files SUFFIXES: SUFFIXES: .nlm .lib .obj .cpp .c .msg .mlc .mdb .xdc .d # Source files C_SRC = php_mysql.c \ start.c CPP_SRC_NODIR = $(notdir $(CPP_SRC)) C_SRC_NODIR = $(notdir $(C_SRC)) SRC_DIR = $(dir $(CPP_SRC) $(C_SRC)) # Library files LIBRARY = $(MYSQL_DIR)/lib/libmysqlclient.lib # Destination directories and files OBJ_DIR = $(BUILD) FINAL_DIR = $(BUILD) OBJECTS = $(addprefix $(OBJ_DIR)/,$(CPP_SRC_NODIR:.c=.obj) $(C_SRC_NODIR:.c=.obj)) DEPDS = $(addprefix $(OBJ_DIR)/,$(CPP_SRC_NODIR:.c=.d) $(C_SRC_NODIR:.c=.d)) # Binary file ifndef BINARY BINARY=$(FINAL_DIR)\$(MODULE_NAME).nlm endif # Compile flags C_FLAGS = -c -maxerrors 25 -msgstyle gcc -wchar_t on -bool on -processor Pentium -align 1 C_FLAGS += -nostdinc -nosyspath C_FLAGS += -DNETWARE -DZTS -DNEW_LIBC -DUSE_OLD_FUNCTIONS -DCOMPILE_DL=1 C_FLAGS += -I. -I$(PROJECT_ROOT)/main -I$(PROJECT_ROOT)/ext/standard -I$(PROJECT_ROOT) -I$(PROJECT_ROOT)/netware C_FLAGS += -I$(PROJECT_ROOT)/zend -I$(PROJECT_ROOT)/tsrm C_FLAGS += -I- -I$(SDK_DIR)/include -I$(MWCIncludes) C_FLAGS += -I$(MYSQL_DIR)/include -DCOMPILE_DL_MYSQL=1 C_FLAGS += -I$(WINSOCK_DIR)/include/nlm -I$(WINSOCK_DIR)/include # Extra stuff based on debug / release builds ifeq '$(BUILD)' 'debug' SYM_FILE = $(FINAL_DIR)\$(MODULE_NAME).sym C_FLAGS += -inline smart -sym on -sym codeview4 -opt off -opt intrinsics -DDEBUGGING -DDKFBPON C_FLAGS += -exc cw -DZEND_DEBUG=1 LD_FLAGS += -sym on -sym codeview4 -osym $(SYM_FILE) export MWLibraryFiles=$(SDK_DIR)/imports/libcpre.o;mwcrtld.lib else C_FLAGS += -opt speed -inline on -inline smart -inline auto -sym off -opt intrinsics C_FLAGS += -opt level=4 -DZEND_DEBUG=0 LD_FLAGS += -sym off export MWLibraryFiles=$(SDK_DIR)/imports/libcpre.o;mwcrtl.lib endif # Dependencies MODULE = LibC\ phplib IMPORT = $(SDK_DIR)/imports/libc.imp\ $(SDK_DIR)/imports/ws2nlm.imp \ $(MPK_DIR)/import/mpkOrg.imp \ $(PROJECT_ROOT)/netware/phplib.imp #EXPORT = mysql_functions\ # mysql_module_entry \ # ($(MODULE_NAME).nlm) get_module EXPORT = ($(MODULE_NAME)) get_module API = OutputToScreen # Virtual paths vpath %.cpp . vpath %.c . ..\..\netware vpath %.obj $(OBJ_DIR) all: prebuild project PHONY: all prebuild: if not exist $(OBJ_DIR) md $(OBJ_DIR) project: $(BINARY) echo Build complete. $(OBJ_DIR)/%.d: %.cpp echo Building Dependencies for $(F) $(CC) -M $ $(C_FLAGS) -o $ $(OBJ_DIR)/%.d: %.c echo Building Dependencies for $(F) $(CC) -M $ $(C_FLAGS) -o $ $(OBJ_DIR)/%.obj: %.cpp echo Compiling $?... $(CC) $ $(C_FLAGS) -o $ $(OBJ_DIR)/%.obj: %.c echo Compiling $?... $(CC) $ $(C_FLAGS) -o $ $(BINARY): $(DEPDS) $(OBJECTS) echo Import $(IMPORT) $(basename $).def ifdef API echo Import $(API) $(basename $).def endif echo Module $(MODULE) $(basename $).def ifdef EXPORT echo Export $(EXPORT) $(basename $).def endif echo AutoUnload $(basename $).def ifeq '$(BUILD)' 'debug' echo Debug $(basename $).def endif echo Flag_On 0x0008 $(basename $).def echo Start _NonAppStart $(basename $).def echo Exit _NonAppStop $(basename $).def echo Linking $... echo $(LD_FLAGS) -commandfile $(basename $).def $(basename $).link echo $(LIBRARY) $(OBJECTS) $(basename $).link $(LINK) $(basename $).link PHONY: clean clean: cleand cleanobj cleanbin PHONY: cleand cleand: echo Deleting all dependency files... -del $(OBJ_DIR)\*.d PHONY: cleanobj cleanobj: echo Deleting all object files... -del $(OBJ_DIR)\*.obj PHONY: cleanbin cleanbin: echo Deleting binary files... -del $(FINAL_DIR)\$(MODULE_NAME).nlm echo Deleting MAP, DEF files, etc -del $(FINAL_DIR)\$(MODULE_NAME).map -del $(FINAL_DIR)\$(MODULE_NAME).def -del $(FINAL_DIR)\$(MODULE_NAME).link ifeq '$(BUILD)' 'debug' -del $(FINAL_DIR)\$(MODULE_NAME).sym endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/mysql php_mysql.c
hyanantha Thu Oct 24 05:55:18 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/mysql php_mysql.c Log: NetWare related changes/modifications. Index: php4/ext/mysql/php_mysql.c diff -u php4/ext/mysql/php_mysql.c:1.116.2.4 php4/ext/mysql/php_mysql.c:1.116.2.5 --- php4/ext/mysql/php_mysql.c:1.116.2.4Wed Aug 28 21:18:28 2002 +++ php4/ext/mysql/php_mysql.c Thu Oct 24 05:55:17 2002 -16,7 +16,7 +--+ */ -/* $Id: php_mysql.c,v 1.116.2.4 2002/08/29 01:18:28 sniper Exp $ */ +/* $Id: php_mysql.c,v 1.116.2.5 2002/10/24 09:55:17 hyanantha Exp $ */ /* TODO: -37,6 +37,10 #ifdef PHP_WIN32 #include winsock.h #define signal(a, b) NULL +#elif defined(NETWARE) +/*#include ws2nlm.h*/ +#include sys/socket.h +#define signal(a, b) NULL #else #include build-defs.h #if HAVE_SIGNAL_H -124,10 +128,12 PHP_FE(mysql_pconnect, NULL) PHP_FE(mysql_close, NULL) PHP_FE(mysql_select_db, NULL) +#ifndef NETWARE/* The below two functions not supported on NetWare */ #if MYSQL_VERSION_ID 4 PHP_FE(mysql_create_db, NULL) PHP_FE(mysql_drop_db, NULL) #endif +#endif /* NETWARE */ PHP_FE(mysql_query, NULL) PHP_FE(mysql_unbuffered_query, NULL) PHP_FE(mysql_db_query, NULL) -173,10 +179,12 PHP_FALIAS(mysql_fieldtype, mysql_field_type, NULL) PHP_FALIAS(mysql_fieldflags,mysql_field_flags, NULL) PHP_FALIAS(mysql_selectdb, mysql_select_db,NULL) +#ifndef NETWARE/* The below two functions not supported on NetWare */ #if MYSQL_VERSION_ID 4 PHP_FALIAS(mysql_createdb, mysql_create_db,NULL) PHP_FALIAS(mysql_dropdb,mysql_drop_db, NULL) #endif +#endif /* NETWARE */ PHP_FALIAS(mysql_freeresult,mysql_free_result, NULL) PHP_FALIAS(mysql_numfields, mysql_num_fields, NULL) PHP_FALIAS(mysql_numrows, mysql_num_rows, NULL) -297,7 +305,7 static PHP_INI_MH(OnMySQLPort) { if (new_value==NULL) { /* default port */ -#ifndef PHP_WIN32 +#if !defined (PHP_WIN32) ! defined (NETWARE) struct servent *serv_ptr; char *env; -427,7 +435,7 sprintf(buf, %ld, MySG(num_links)); php_info_print_table_row(2, Active Links, buf); php_info_print_table_row(2, Client API version, mysql_get_client_info()); -#ifndef PHP_WIN32 +#if !defined (PHP_WIN32) !defined (NETWARE) php_info_print_table_row(2, MYSQL_MODULE_TYPE, PHP_MYSQL_TYPE); php_info_print_table_row(2, MYSQL_SOCKET, MYSQL_UNIX_ADDR); php_info_print_table_row(2, MYSQL_INCLUDE, PHP_MYSQL_INCLUDE); -834,7 +842,7 WRONG_PARAM_COUNT; } - RETURN_STRING(mysql_get_client_info(),1); + RETURN_STRING((char *)mysql_get_client_info(),1); /* Type-casting done +due to NetWare */ } /* }}} */ -864,7 +872,7 ZEND_FETCH_RESOURCE2(mysql, php_mysql_conn *, mysql_link, id, MySQL-Link, le_link, le_plink); - RETURN_STRING(mysql_get_host_info(mysql-conn),1); + RETURN_STRING((char *)mysql_get_host_info(mysql-conn),1); /* +Type-casting done due to NetWare */ } /* }}} */ -924,12 +932,14 ZEND_FETCH_RESOURCE2(mysql, php_mysql_conn *, mysql_link, id, MySQL-Link, le_link, le_plink); - RETURN_STRING(mysql_get_server_info(mysql-conn),1); + RETURN_STRING((char *)mysql_get_server_info(mysql-conn),1); /* +Type-casting done due to NetWare */ } /* }}} */ #endif +#ifndef NETWARE/* The below two functions not supported on NetWare */ + #if MYSQL_VERSION_ID 4 /* {{{ proto bool mysql_create_db(string database_name [, int link_identifier]) Create a MySQL database */ -1009,6 +1019,8 /* }}} */ #endif +#endif /* NETWARE */ + /* {{{ php_mysql_do_query_general */ static void php_mysql_do_query_general(zval **query, zval **mysql_link, int link_id, zval **db, int use_store, zval *return_value TSRMLS_DC) -1310,7 +1322,7 ZEND_FETCH_RESOURCE2(mysql, php_mysql_conn *, mysql_link, id, MySQL-Link, le_link, le_plink); - RETURN_STRING(mysql_error(mysql-conn), 1); + RETURN_STRING((char *)mysql_error(mysql-conn), 1);/* Type-casting done +due to NetWare */ } /*
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/pcre/pcrelib internal.h
hyanantha Thu Oct 24 05:55:54 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/pcre/pcrelib internal.h Log: NetWare related changes/modifications. Index: php4/ext/pcre/pcrelib/internal.h diff -u php4/ext/pcre/pcrelib/internal.h:1.9 php4/ext/pcre/pcrelib/internal.h:1.9.8.1 --- php4/ext/pcre/pcrelib/internal.h:1.9Tue Feb 20 17:00:30 2001 +++ php4/ext/pcre/pcrelib/internal.hThu Oct 24 05:55:54 2002 -39,6 +39,8 #ifdef PHP_WIN32 #include config.w32.h +#elif defined(NETWARE) +#include config.nw.h #else #include php_config.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/pgsql pgsql.mak
hyanantha Thu Oct 24 05:56:44 2002 EDT Added files: (Branch: PHP_4_2_0) /php4/ext/pgsql pgsql.mak Log: NetWare related file. Index: php4/ext/pgsql/pgsql.mak +++ php4/ext/pgsql/pgsql.mak -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/pgsql php_pgsql.h
hyanantha Thu Oct 24 05:57:26 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/pgsql php_pgsql.h Log: NetWare related changes/modifications. Index: php4/ext/pgsql/php_pgsql.h diff -u php4/ext/pgsql/php_pgsql.h:1.39 php4/ext/pgsql/php_pgsql.h:1.39.2.1 --- php4/ext/pgsql/php_pgsql.h:1.39 Wed Feb 6 02:25:51 2002 +++ php4/ext/pgsql/php_pgsql.h Thu Oct 24 05:57:25 2002 -17,7 +17,7 +--+ */ -/* $Id: php_pgsql.h,v 1.39 2002/02/06 07:25:51 yohgaki Exp $ */ +/* $Id: php_pgsql.h,v 1.39.2.1 2002/10/24 09:57:25 hyanantha Exp $ */ #ifndef PHP_PGSQL_H #define PHP_PGSQL_H -34,6 +34,8 #ifdef PHP_WIN32 #define INV_WRITE0x0002 #define INV_READ 0x0004 +#elif defined NETWARE +#include libpq-fs.h #else #include libpq/libpq-fs.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/session mod_files.c
hyanantha Thu Oct 24 05:58:48 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/session mod_files.c Log: NetWare related changes/modifications. Index: php4/ext/session/mod_files.c diff -u php4/ext/session/mod_files.c:1.72.2.3 php4/ext/session/mod_files.c:1.72.2.4 --- php4/ext/session/mod_files.c:1.72.2.3 Wed Sep 4 09:50:38 2002 +++ php4/ext/session/mod_files.cThu Oct 24 05:58:47 2002 -16,7 +16,7 +--+ */ -/* $Id: mod_files.c,v 1.72.2.3 2002/09/04 13:50:38 kalowsky Exp $ */ +/* $Id: mod_files.c,v 1.72.2.4 2002/10/24 09:58:47 hyanantha Exp $ */ #include php.h -156,7 +156,11 DIR *dir; char dentry[sizeof(struct dirent) + MAXPATHLEN]; struct dirent *entry = (struct dirent *) dentry; +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) +struct stat_libc sbuf; +#else struct stat sbuf; +#endif char buf[MAXPATHLEN]; time_t now; int nrdels = 0; -190,7 +194,11 buf[dirname_len + entry_len + 1] = '\0'; /* check whether its last access was more than maxlifet ago */ if (VCWD_STAT(buf, sbuf) == 0 - (now - sbuf.st_atime) maxlifetime) { +#if (defined(NETWARE) defined(NEW_LIBC)) + (now - sbuf.st_atime.tv_nsec) +maxlifetime) { +#else +(now - sbuf.st_atime) maxlifetime) { +#endif VCWD_UNLINK(buf); nrdels++; } -242,14 +250,22 PS_READ_FUNC(files) { long n; +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) +struct stat_libc sbuf; +#else struct stat sbuf; +#endif PS_FILES_DATA; ps_files_open(data, key TSRMLS_CC); if (data-fd 0) return FAILURE; +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) + if (fstat(data-fd, ((struct stat*)sbuf))) +#else if (fstat(data-fd, sbuf)) +#endif return FAILURE; data-st_size = *vallen = sbuf.st_size; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/snmp snmp.c
hyanantha Thu Oct 24 05:59:31 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/snmp snmp.c Log: NetWare related changes/modifications. Index: php4/ext/snmp/snmp.c diff -u php4/ext/snmp/snmp.c:1.56 php4/ext/snmp/snmp.c:1.56.2.1 --- php4/ext/snmp/snmp.c:1.56 Thu Feb 28 22:31:01 2002 +++ php4/ext/snmp/snmp.cThu Oct 24 05:59:31 2002 @@ -17,7 +17,7 @@ | Steven Lawrance [EMAIL PROTECTED]| +--+ */ -/* $Id: snmp.c,v 1.56 2002/03/01 03:31:01 yohgaki Exp $ */ +/* $Id: snmp.c,v 1.56.2.1 2002/10/24 09:59:31 hyanantha Exp $ */ #ifdef HAVE_CONFIG_H #include config.h @@ -32,6 +32,20 @@ #include errno.h #include process.h #include win32/time.h +#elif defined(NETWARE) +#ifdef USE_WINSOCK +/*#include ws2nlm.h*/ +#include novsock2.h +#else +#include sys/socket.h +#endif +#include errno.h +/*#include process.h*/ +#ifdef NEW_LIBC +#include sys/timeval.h +#else +#include netware/time_nw.h +#endif #else #include sys/socket.h #include netinet/in.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/session session.c
sas Thu Oct 24 06:40:49 2002 EDT Modified files: /php4/ext/session session.c Log: improved warning message # this should really link to an external page which explains the issue deeply Index: php4/ext/session/session.c diff -u php4/ext/session/session.c:1.335 php4/ext/session/session.c:1.336 --- php4/ext/session/session.c:1.335Sun Oct 6 22:37:50 2002 +++ php4/ext/session/session.c Thu Oct 24 06:40:48 2002 -17,7 +17,7 +--+ */ -/* $Id: session.c,v 1.335 2002/10/07 02:37:50 sas Exp $ */ +/* $Id: session.c,v 1.336 2002/10/24 10:40:48 sas Exp $ */ #ifdef HAVE_CONFIG_H #include config.h -663,7 +663,7 } if (do_warn PS(bug_compat_warn)) { - php_error(E_WARNING, Your script possibly relies on a session side-effect which existed until PHP 4.2.3. Please be advised that the session extension does not consider global variables as a source of data, unless register_globals is enabled. You can disable this functionality and this warning by setting session.bug_compat_42 or session.bug_compat_warn.); + php_error(E_WARNING, Your script possibly relies on a +session side-effect which existed until PHP 4.2.3. Please be advised that the session +extension does not consider global variables as a source of data, unless +register_globals is enabled. You can disable this functionality and this warning by +setting session.bug_compat_42 or session.bug_compat_warn to off, respectively.); } } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 / acinclude.m4
sas Thu Oct 24 06:41:37 2002 EDT Modified files: /php4 acinclude.m4 Log: Quote macro names in AC_DEFUN() and prefix the internal macros using a single underscore. Also rename AC_PHP_ONCE as PHP_RUN_ONCE. Index: php4/acinclude.m4 diff -u php4/acinclude.m4:1.214 php4/acinclude.m4:1.215 --- php4/acinclude.m4:1.214 Sun Oct 20 23:31:52 2002 +++ php4/acinclude.m4 Thu Oct 24 06:41:36 2002 @@ -1,4 +1,4 @@ -dnl $Id: acinclude.m4,v 1.214 2002/10/21 03:31:52 sniper Exp $ +dnl $Id: acinclude.m4,v 1.215 2002/10/24 10:41:36 sas Exp $ dnl dnl This file contains local autoconf functions. @@ -9,7 +9,7 @@ dnl are substituted with the proper paths. Can be used to supply dnl custom rules and/or additional targets. dnl -AC_DEFUN(PHP_ADD_MAKEFILE_FRAGMENT,[ +AC_DEFUN([PHP_ADD_MAKEFILE_FRAGMENT],[ ifelse($1,,src=$ext_srcdir/Makefile.frag,src=$1) ifelse($2,,ac_srcdir=$ext_srcdir,ac_srcdir=$2) ifelse($3,,ac_builddir=$ext_builddir,ac_builddir=$3) @@ -21,13 +21,13 @@ dnl dnl Creates builddir/include/what.h and in there #define WHAT value dnl -AC_DEFUN(PHP_DEFINE,[ +AC_DEFUN([PHP_DEFINE],[ [echo #define ]$1[]ifelse([$2],,[ 1],[ $2])[ include/php_]translit($1,A-Z,a-z)[.h] ]) dnl PHP_INIT_BUILD_SYSTEM dnl -AC_DEFUN(PHP_INIT_BUILD_SYSTEM,[ +AC_DEFUN([PHP_INIT_BUILD_SYSTEM],[ mkdir include /dev/null 21 Makefile.objects Makefile.fragments @@ -40,7 +40,7 @@ dnl dnl Generates the global makefile. dnl -AC_DEFUN(PHP_GEN_GLOBAL_MAKEFILE,[ +AC_DEFUN([PHP_GEN_GLOBAL_MAKEFILE],[ cat Makefile EOF srcdir = $abs_srcdir builddir = $abs_builddir @@ -66,13 +66,13 @@ dnl the path is interpreted relative to the top build-directory. dnl dnl which array to append to? -AC_DEFUN(PHP_ADD_SOURCES,[ +AC_DEFUN([PHP_ADD_SOURCES],[ PHP_ADD_SOURCES_X($1, $2, $3, ifelse($4,cli,PHP_CLI_OBJS,ifelse($4,sapi,PHP_SAPI_OBJS,PHP_GLOBAL_OBJS))) ]) dnl -dnl PHP_ASSIGN_BUILD_VARS(type) +dnl _PHP_ASSIGN_BUILD_VARS(type) dnl internal, don't use -AC_DEFUN(PHP_ASSIGN_BUILD_VARS,[ +AC_DEFUN([_PHP_ASSIGN_BUILD_VARS],[ ifelse($1,shared,[ b_c_pre=$shared_c_pre b_cxx_pre=$shared_cxx_pre @@ -98,7 +98,7 @@ dnl shared objects will be built from the sources. Should not be dnl used directly. dnl -AC_DEFUN(PHP_ADD_SOURCES_X,[ +AC_DEFUN([PHP_ADD_SOURCES_X],[ dnl relative to source- or build-directory? dnl ac_srcdir/ac_bdir include trailing slash case $1 in @@ -108,7 +108,7 @@ esac dnl how to build .. shared or static? - ifelse($5,yes,PHP_ASSIGN_BUILD_VARS(shared),PHP_ASSIGN_BUILD_VARS(php)) + ifelse($5,yes,_PHP_ASSIGN_BUILD_VARS(shared),_PHP_ASSIGN_BUILD_VARS(php)) dnl iterate over the sources old_IFS=[$]IFS @@ -140,14 +140,14 @@ dnl dnl Disable building CLI dnl -AC_DEFUN(PHP_DISABLE_CLI,[ +AC_DEFUN([PHP_DISABLE_CLI],[ disable_cli=1 ]) dnl dnl Separator into the configure --help display. dnl -AC_DEFUN(PHP_HELP_SEPARATOR,[ +AC_DEFUN([PHP_HELP_SEPARATOR],[ AC_ARG_ENABLE([],[ $1 ],[]) @@ -163,7 +163,7 @@ dnl dnl If successful, adds -rdynamic to PHP_LDFLAGS. dnl -AC_DEFUN(PHP_TARGET_RDYNAMIC,[ +AC_DEFUN([PHP_TARGET_RDYNAMIC],[ if test -n $GCC; then dnl we should use a PHP-specific macro here TSRM_CHECK_GCC_ARG(-rdynamic, gcc_rdynamic=yes) @@ -173,7 +173,7 @@ fi ]) -AC_DEFUN(PHP_REMOVE_USR_LIB,[ +AC_DEFUN([PHP_REMOVE_USR_LIB],[ unset ac_new_flags for i in [$]$1; do case [$]i in @@ -184,7 +184,7 @@ $1=[$]ac_new_flags ]) -AC_DEFUN(PHP_SETUP_OPENSSL,[ +AC_DEFUN([PHP_SETUP_OPENSSL],[ if test $PHP_OPENSSL = yes; then PHP_OPENSSL=/usr/local/ssl /usr/local /usr /usr/local/openssl fi @@ -250,7 +250,7 @@ dnl paths to the PHP build system which are only given in compiler dnl notation. dnl -AC_DEFUN(PHP_EVAL_LIBLINE,[ +AC_DEFUN([PHP_EVAL_LIBLINE],[ for ac_i in $1; do case $ac_i in -l*) @@ -270,7 +270,7 @@ dnl Use this macro, if you need to add header search paths to the PHP dnl build system which are only given in compiler notation. dnl -AC_DEFUN(PHP_EVAL_INCLINE,[ +AC_DEFUN([PHP_EVAL_INCLINE],[ for ac_i in $1; do case $ac_i in -I*) @@ -281,7 +281,7 @@ done ]) -AC_DEFUN(PHP_READDIR_R_TYPE,[ +AC_DEFUN([PHP_READDIR_R_TYPE],[ dnl HAVE_READDIR_R is also defined by libmysql AC_CHECK_FUNC(readdir_r,ac_cv_func_readdir_r=yes,ac_cv_func_readdir=no) if test $ac_cv_func_readdir_r = yes; then @@ -333,7 +333,7 @@ fi ]) -AC_DEFUN(PHP_SHLIB_SUFFIX_NAME,[ +AC_DEFUN([PHP_SHLIB_SUFFIX_NAME],[ PHP_SUBST(SHLIB_SUFFIX_NAME) SHLIB_SUFFIX_NAME=so case $host_alias in @@ -346,7 +346,7 @@ esac ]) -AC_DEFUN(PHP_DEBUG_MACRO,[ +AC_DEFUN([PHP_DEBUG_MACRO],[ DEBUG_LOG=$1 cat $1 X CONFIGURE: $CONFIGURE_COMMAND @@ -374,7 +374,7 @@ rm -fr conftest* ]) -AC_DEFUN(PHP_DOES_PWRITE_WORK,[ +AC_DEFUN([PHP_DOES_PWRITE_WORK],[ AC_TRY_RUN([ #include sys/types.h #include sys/stat.h @@ -401,7 +401,7 @@ ]) ]) -AC_DEFUN(PHP_DOES_PREAD_WORK,[
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard base64.c
hyanantha Thu Oct 24 07:11:42 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard base64.c Log: NetWare related changes/modifications. Index: php4/ext/standard/base64.c diff -u php4/ext/standard/base64.c:1.29.2.1 php4/ext/standard/base64.c:1.29.2.2 --- php4/ext/standard/base64.c:1.29.2.1 Wed May 1 16:12:51 2002 +++ php4/ext/standard/base64.c Thu Oct 24 07:11:41 2002 @@ -15,7 +15,7 @@ | Author: Jim Winstead [EMAIL PROTECTED] | +--+ */ -/* $Id: base64.c,v 1.29.2.1 2002/05/01 20:12:51 derick Exp $ */ +/* $Id: base64.c,v 1.29.2.2 2002/10/24 11:11:41 hyanantha Exp $ */ #include string.h @@ -160,9 +160,9 @@ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, s, str, str_len) == FAILURE) { return; } - result = php_base64_encode(str, str_len, ret_length); + result = php_base64_encode((const unsigned char*)str, str_len, ret_length); + /* type-casting done due to NetWare */ if (result != NULL) { - RETVAL_STRINGL(result, ret_length, 0); + RETVAL_STRINGL((char*)result, ret_length, 0); /* type-casting done +due to NetWare */ } else { RETURN_FALSE; } @@ -181,9 +181,9 @@ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, s, str, str_len) == FAILURE) { return; } - result = php_base64_decode(str, str_len, ret_length); + result = php_base64_decode((const unsigned char*)str, str_len, ret_length); + /* type-casting done due to NetWare */ if (result != NULL) { - RETVAL_STRINGL(result, ret_length, 0); + RETVAL_STRINGL((char*)result, ret_length, 0); /* type-casting done +due to NetWare */ } else { RETURN_FALSE; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard basic_functions.c
hyanantha Thu Oct 24 07:12:10 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard basic_functions.c Log: NetWare related changes/modifications. Index: php4/ext/standard/basic_functions.c diff -u php4/ext/standard/basic_functions.c:1.447.2.7 php4/ext/standard/basic_functions.c:1.447.2.8 --- php4/ext/standard/basic_functions.c:1.447.2.7 Fri Aug 23 20:44:03 2002 +++ php4/ext/standard/basic_functions.c Thu Oct 24 07:12:10 2002 -17,7 +17,7 +--+ */ -/* $Id: basic_functions.c,v 1.447.2.7 2002/08/24 00:44:03 zeev Exp $ */ +/* $Id: basic_functions.c,v 1.447.2.8 2002/10/24 11:12:10 hyanantha Exp $ */ #include php.h #include php_main.h -38,6 +38,20 #include stdio.h #include netdb.h +/* Additional headers for NetWare */ +#ifdef NETWARE +/*#include netware/env.h*//* Temporary */ +#ifdef NEW_LIBC /* Same headers hold good for Winsock and Berkeley sockets */ +#include netinet/in.h +/*#include arpa/inet.h*/ +#include netdb.h +#else +#include sys/socket.h +#endif +#else +#include netdb.h +#endif + #if HAVE_ARPA_INET_H # include arpa/inet.h #endif -415,7 +429,7 PHP_FE(gethostbyname, NULL) PHP_FE(gethostbynamel, NULL) -#if HAVE_RES_SEARCH !(defined(__BEOS__) || defined(PHP_WIN32)) +#if HAVE_RES_SEARCH !(defined(__BEOS__) || defined(PHP_WIN32) || defined(NETWARE)) PHP_FE(checkdnsrr, NULL) PHP_FE(getmxrr,second_and_third_args_force_ref) #else -447,7 +461,7 PHP_FE(cosh, NULL) PHP_FE(tanh, NULL) -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) PHP_FE(asinh, NULL) PHP_FE(acosh, NULL) PHP_FE(atanh, NULL) -634,7 +648,7 PHP_FE(socket_get_status, NULL) -#if (!defined(PHP_WIN32) !defined(__BEOS__) HAVE_REALPATH) || defined(ZTS) +#if (!defined(PHP_WIN32) !defined(__BEOS__) HAVE_REALPATH !defined(NETWARE)) +|| defined(ZTS) PHP_FE(realpath, NULL) #else PHP_FALIAS(realpath,warn_not_available, NULL) -1001,7 +1015,9 PHP_MINIT(lcg) (INIT_FUNC_ARGS_PASSTHRU); PHP_MINIT(dir) (INIT_FUNC_ARGS_PASSTHRU); +#ifdef HAVE_SYSLOG_H PHP_MINIT(syslog) (INIT_FUNC_ARGS_PASSTHRU); +#endif PHP_MINIT(array) (INIT_FUNC_ARGS_PASSTHRU); PHP_MINIT(assert) (INIT_FUNC_ARGS_PASSTHRU); PHP_MINIT(url_scanner_ex) (INIT_FUNC_ARGS_PASSTHRU); -1082,7 +1098,9 PHP_RINIT(lcg) (INIT_FUNC_ARGS_PASSTHRU); PHP_RINIT(filestat) (INIT_FUNC_ARGS_PASSTHRU); +#ifdef HAVE_SYSLOG_H PHP_RINIT(syslog) (INIT_FUNC_ARGS_PASSTHRU); +#endif PHP_RINIT(dir) (INIT_FUNC_ARGS_PASSTHRU); /* Reset magic_quotes_runtime */ -1113,7 +1131,9 PHP_RSHUTDOWN(fsock) (SHUTDOWN_FUNC_ARGS_PASSTHRU); PHP_RSHUTDOWN(filestat) (SHUTDOWN_FUNC_ARGS_PASSTHRU); +#ifdef HAVE_SYSLOG_H PHP_RSHUTDOWN(syslog) (SHUTDOWN_FUNC_ARGS_PASSTHRU); +#endif PHP_RSHUTDOWN(assert) (SHUTDOWN_FUNC_ARGS_PASSTHRU); if (BG(user_tick_functions)) { -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard datetime.c
hyanantha Thu Oct 24 07:12:44 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard datetime.c Log: NetWare related changes/modifications. Index: php4/ext/standard/datetime.c diff -u php4/ext/standard/datetime.c:1.83.2.1 php4/ext/standard/datetime.c:1.83.2.2 --- php4/ext/standard/datetime.c:1.83.2.1 Mon Jul 22 18:07:11 2002 +++ php4/ext/standard/datetime.cThu Oct 24 07:12:44 2002 -19,7 +19,7 */ -/* $Id: datetime.c,v 1.83.2.1 2002/07/22 22:07:11 jan Exp $ */ +/* $Id: datetime.c,v 1.83.2.2 2002/10/24 11:12:44 hyanantha Exp $ */ #include php.h -55,6 +55,9 }; #if !defined(HAVE_TM_ZONE) !defined(_TIMEZONE) !defined(HAVE_DECLARED_TIMEZONE) +#if defined(NETWARE) (NEW_LIBC) +#define timezone_timezone /* Do not know why this is called '_timezone' in new +version of LibC */ +#endif extern time_t timezone; extern int daylight; #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard dl.c
hyanantha Thu Oct 24 07:12:59 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard dl.c Log: NetWare related changes/modifications. Index: php4/ext/standard/dl.c diff -u php4/ext/standard/dl.c:1.66.2.1 php4/ext/standard/dl.c:1.66.2.2 --- php4/ext/standard/dl.c:1.66.2.1 Mon Mar 25 18:22:05 2002 +++ php4/ext/standard/dl.c Thu Oct 24 07:12:59 2002 -18,7 +18,7 +--+ */ -/* $Id: dl.c,v 1.66.2.1 2002/03/25 23:22:05 sniper Exp $ */ +/* $Id: dl.c,v 1.66.2.2 2002/10/24 11:12:59 hyanantha Exp $ */ #include php.h #include dl.h -26,7 +26,7 #include ext/standard/info.h #include SAPI.h -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) #include build-defs.h #endif -43,6 +43,13 #include win32/param.h #include win32/winutil.h #define GET_DL_ERROR() php_win_err() +#elif defined(NETWARE) +#ifdef NEW_LIBC +#include sys/param.h +#else +#include netware/param.h +#endif +#define GET_DL_ERROR() dlerror() #else #include sys/param.h #define GET_DL_ERROR() dlerror() -141,7 +148,23 efree(libpath); - + +#ifdef NETWARE + /* NetWare doesn't support two NLMs exporting same symbol */ +{ +char symbol_name[64] = \0; +int module_name_length = Z_STRLEN_P(file) - 4; /* '.nlm' is 4 characters; +knock it off */ + +/* Take the module name (e.g.: 'php_ldap') and append 'get_module' to it */ +strncpy(symbol_name, Z_STRVAL_P(file), module_name_length); +symbol_name[module_name_length] = '\0'; +strcat(symbol_name, ); +strcat(symbol_name, get_module); + +get_module = (zend_module_entry *(*)(void)) DL_FETCH_SYMBOL(handle, +symbol_name); + } +/* NetWare doesn't prepend _ to symbol names. So, that portion of code is also +not necessary */ +#else get_module = (zend_module_entry *(*)(void)) DL_FETCH_SYMBOL(handle, get_module); /* -152,6 +175,7 if (!get_module) get_module = (zend_module_entry *(*)(void)) DL_FETCH_SYMBOL(handle, _get_module); +#endif if (!get_module) { DL_UNLOAD(handle); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard dns.c
hyanantha Thu Oct 24 07:13:19 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard dns.c Log: NetWare related changes/modifications. Index: php4/ext/standard/dns.c diff -u php4/ext/standard/dns.c:1.38.2.2 php4/ext/standard/dns.c:1.38.2.3 --- php4/ext/standard/dns.c:1.38.2.2Thu Aug 29 11:59:54 2002 +++ php4/ext/standard/dns.c Thu Oct 24 07:13:19 2002 -16,7 +16,7 +--+ */ -/* $Id: dns.c,v 1.38.2.2 2002/08/29 15:59:54 iliaa Exp $ */ +/* $Id: dns.c,v 1.38.2.3 2002/10/24 11:13:19 hyanantha Exp $ */ /* {{{ includes */ -42,7 +42,7 #endif #endif #include winsock.h -#else +#else /* This holds good for NetWare too, both for Winsock and Berkeley sockets */ #include netinet/in.h #if HAVE_ARPA_INET_H #include arpa/inet.h -60,6 +60,11 #endif #endif +/* Borrowed from SYS/SOCKET.H */ +#if defined(NETWARE) defined(USE_WINSOCK) +#define AF_INET 2 /* internetwork: UDP, TCP, etc. */ +#endif + #include dns.h /* }}} */ -201,7 +206,7 } /* }}} */ -#if HAVE_RES_SEARCH !(defined(__BEOS__)||defined(PHP_WIN32)) +#if HAVE_RES_SEARCH !(defined(__BEOS__)||defined(PHP_WIN32) || defined(NETWARE)) /* {{{ proto int checkdnsrr(string host [, string type]) Check DNS records corresponding to a given Internet host name or IP address */ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard filestat.c
hyanantha Thu Oct 24 07:14:04 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard filestat.c Log: NetWare related changes/modifications. Index: php4/ext/standard/filestat.c diff -u php4/ext/standard/filestat.c:1.89.2.7 php4/ext/standard/filestat.c:1.89.2.8 --- php4/ext/standard/filestat.c:1.89.2.7 Tue Sep 10 20:41:17 2002 +++ php4/ext/standard/filestat.cThu Oct 24 07:14:04 2002 -16,7 +16,7 +--+ */ -/* $Id: filestat.c,v 1.89.2.7 2002/09/11 00:41:17 edink Exp $ */ +/* $Id: filestat.c,v 1.89.2.8 2002/10/24 11:14:04 hyanantha Exp $ */ #include php.h #include safe_mode.h -54,6 +54,8 #if HAVE_PWD_H # ifdef PHP_WIN32 # include win32/pwd.h +# elif defined(NETWARE) +# include netware/pwd.h # else # include pwd.h # endif -335,7 +337,7 Change file group */ PHP_FUNCTION(chgrp) { -#ifndef WINDOWS +#if !defined(WINDOWS) !defined(NETWARE) /* 'chgrp' is not available on NetWare +also */ pval **filename, **group; gid_t gid; struct group *gr=NULL; -383,7 +385,7 Change file owner */ PHP_FUNCTION(chown) { -#ifndef WINDOWS +#if !defined(WINDOWS) !defined(NETWARE) /* 'chown' is not available on NetWare +also */ pval **filename, **user; int ret; uid_t uid; -472,7 +474,12 { pval **filename, **filetime, **fileatime; int ret; +#if defined(NETWARE) defined(CLIB_STAT_PATCH) +struct stat_libc sb; +#else struct stat sb; +#endif + FILE *file; struct utimbuf newtimebuf; struct utimbuf *newtime = NULL; -546,7 +553,11 { zval *stat_dev, *stat_ino, *stat_mode, *stat_nlink, *stat_uid, *stat_gid, *stat_rdev, *stat_size, *stat_atime, *stat_mtime, *stat_ctime, *stat_blksize, *stat_blocks; +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) +struct stat_libc *stat_sb; +#else struct stat *stat_sb; +#endif int rmask=S_IROTH, wmask=S_IWOTH, xmask=S_IXOTH; /* access rights defaults to other */ char *stat_sb_names[13]={dev, ino, mode, nlink, uid, gid, rdev, size, atime, mtime, ctime, blksize, blocks}; -559,7 +570,11 RETURN_FALSE; } +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) + stat_sb = (struct stat_libc *)BG(sb); +#else stat_sb = BG(sb); +#endif if (!BG(CurrentStatFile) || strcmp(filename, BG(CurrentStatFile))) { if (!BG(CurrentStatFile) || filename_length BG(CurrentStatLength)) { -574,7 +589,12 #if HAVE_SYMLINK BG(lsb).st_mode = 0; /* mark lstat buf invalid */ #endif + +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) + if (VCWD_STAT(BG(CurrentStatFile), (struct stat_libc *)BG(sb)) == -1) +{ +#else if (VCWD_STAT(BG(CurrentStatFile), BG(sb)) == -1) { +#endif if (!IS_LINK_OPERATION(type) (!IS_EXISTS_CHECK(type) || errno != ENOENT)) { /* fileexists() test must print no error */ php_error(E_WARNING, stat failed for %s (errno=%d - %s), BG(CurrentStatFile), errno, strerror(errno)); } -599,6 +619,7 #endif +#ifndef NETWARE if (type = FS_IS_W type = FS_IS_X) { if(BG(sb).st_uid==getuid()) { rmask=S_IRUSR; -628,6 +649,7 } } } +#endif /* NETWARE */ switch (type) { case FS_PERMS: -641,11 +663,23 case FS_GROUP: RETURN_LONG((long)BG(sb).st_gid); case FS_ATIME: +#if defined(NETWARE) defined(NEW_LIBC) + RETURN_LONG((long)struct stat_libc *)stat_sb)-st_atime).tv_sec)); +#else RETURN_LONG((long)BG(sb).st_atime); +#endif case FS_MTIME: +#if defined(NETWARE) defined(NEW_LIBC) + RETURN_LONG((long)struct stat_libc *)stat_sb)-st_mtime).tv_sec)); +#else RETURN_LONG((long)BG(sb).st_mtime); +#endif case FS_CTIME: +#if defined(NETWARE) defined(NEW_LIBC) + RETURN_LONG((long)struct stat_libc *)stat_sb)-st_ctime).tv_sec)); +#else RETURN_LONG((long)BG(sb).st_ctime); +#endif case FS_TYPE: #if HAVE_SYMLINK if (S_ISLNK(BG(lsb).st_mode)) { -665,19 +699,25 php_error(E_WARNING, Unknown file type (%d), BG(sb).st_modeS_IFMT); RETURN_STRING(unknown, 1); case FS_IS_W: + #ifndef NETWARE /* getuid is not available on NetWare */ if (getuid()==0) { RETURN_TRUE; /* root */ } + #endif /* NETWARE */ RETURN_BOOL((BG(sb).st_mode wmask) != 0); case FS_IS_R: + #ifndef NETWARE /* getuid is not available on NetWare */ if (getuid()==0) {
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard flock_compat.c
hyanantha Thu Oct 24 07:14:33 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard flock_compat.c Log: NetWare related changes/modifications. Index: php4/ext/standard/flock_compat.c diff -u php4/ext/standard/flock_compat.c:1.16 php4/ext/standard/flock_compat.c:1.16.2.1 --- php4/ext/standard/flock_compat.c:1.16 Thu Feb 28 03:26:45 2002 +++ php4/ext/standard/flock_compat.cThu Oct 24 07:14:33 2002 -16,7 +16,7 +--+ */ -/* $Id: flock_compat.c,v 1.16 2002/02/28 08:26:45 sebastian Exp $ */ +/* $Id: flock_compat.c,v 1.16.2.1 2002/10/24 11:14:33 hyanantha Exp $ */ #include php.h #include errno.h -30,6 +30,14 #ifdef PHP_WIN32 #include windows.h #include io.h +#endif + +#ifdef NETWARE +#ifdef NEW_LIBC +#include netinet/in.h +#else +#include sys/socket.h +#endif #endif #ifndef HAVE_FLOCK -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard fsock.c
hyanantha Thu Oct 24 07:14:58 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard fsock.c Log: NetWare related changes/modifications. Index: php4/ext/standard/fsock.c diff -u php4/ext/standard/fsock.c:1.84.2.2 php4/ext/standard/fsock.c:1.84.2.3 --- php4/ext/standard/fsock.c:1.84.2.2 Mon Mar 18 17:12:57 2002 +++ php4/ext/standard/fsock.c Thu Oct 24 07:14:58 2002 -18,7 +18,7 +--+ */ -/* $Id: fsock.c,v 1.84.2.2 2002/03/18 22:12:57 derick Exp $ */ +/* $Id: fsock.c,v 1.84.2.3 2002/10/24 11:14:58 hyanantha Exp $ */ /* Synced with php 3.0 revision 1.121 1999-06-18 [ssb] */ /* Synced with php 3.0 revision 1.133 1999-07-21 [sas] */ -45,6 +45,19 #endif #ifdef PHP_WIN32 #include winsock.h +#elif defined(NETWARE) +#ifdef NEW_LIBC +#ifdef USE_WINSOCK +#include novsock2.h +#else +#include netinet/in.h +#include netdb.h +/*#include sys/socket.h*/ +#include sys/select.h +/*#else +#include sys/socket.h*/ +#endif +#endif #else #include netinet/in.h #include netdb.h -52,7 +65,7 #include arpa/inet.h #endif #endif -#if defined(PHP_WIN32) || defined(__riscos__) +#if defined(PHP_WIN32) || defined(__riscos__) || defined(NETWARE) #undef AF_UNIX #endif #if defined(AF_UNIX) -111,6 +124,10 #ifdef PHP_WIN32 #define EWOULDBLOCK WSAEWOULDBLOCK +#elif defined(NETWARE) +#ifdef USE_WINSOCK +#define EWOULDBLOCK WSAEWOULDBLOCK +#endif #else #include build-defs.h #endif -320,7 +337,7 } #define TOREAD(sock) ((sock)-writepos - (sock)-readpos) -#define READPTR(sock) ((sock)-readbuf + (sock)-readpos) +#define READPTR(sock) ((char *)(sock)-readbuf + (sock)-readpos) /* +Type-casting done due to NetWare */ #define WRITEPTR(sock) ((sock)-readbuf + (sock)-writepos) #define SOCK_FIND(sock, socket) \ php_sockbuf *sock; \ -393,7 +410,7 return ret; } -#if !defined(PHP_WIN32) +#if !defined(PHP_WIN32) !(defined(NETWARE) defined(USE_WINSOCK)) #undef closesocket #define closesocket close #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard fsock.h
hyanantha Thu Oct 24 07:15:10 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard fsock.h Log: NetWare related changes/modifications. Index: php4/ext/standard/fsock.h diff -u php4/ext/standard/fsock.h:1.41 php4/ext/standard/fsock.h:1.41.2.1 --- php4/ext/standard/fsock.h:1.41 Thu Feb 28 03:26:45 2002 +++ php4/ext/standard/fsock.h Thu Oct 24 07:15:09 2002 -18,12 +18,20 +--+ */ -/* $Id: fsock.h,v 1.41 2002/02/28 08:26:45 sebastian Exp $ */ +/* $Id: fsock.h,v 1.41.2.1 2002/10/24 11:15:09 hyanantha Exp $ */ /* Synced with php 3.0 revision 1.24 1999-06-18 [ssb] */ #ifndef FSOCK_H #define FSOCK_H + +#ifdef NETWARE +#ifdef NEW_LIBC +#include sys/timeval.h +#else +#include netware/time_nw.h/* For 'timeval' */ +#endif +#endif #include file.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard ftp_fopen_wrapper.c
hyanantha Thu Oct 24 07:15:33 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard ftp_fopen_wrapper.c Log: NetWare related changes/modifications. Index: php4/ext/standard/ftp_fopen_wrapper.c diff -u php4/ext/standard/ftp_fopen_wrapper.c:1.14 php4/ext/standard/ftp_fopen_wrapper.c:1.14.2.1 --- php4/ext/standard/ftp_fopen_wrapper.c:1.14 Thu Feb 28 03:26:45 2002 +++ php4/ext/standard/ftp_fopen_wrapper.c Thu Oct 24 07:15:33 2002 @@ -17,7 +17,7 @@ | Hartmut Holzgraefe [EMAIL PROTECTED] | +--+ */ -/* $Id: ftp_fopen_wrapper.c,v 1.14 2002/02/28 08:26:45 sebastian Exp $ */ +/* $Id: ftp_fopen_wrapper.c,v 1.14.2.1 2002/10/24 11:15:33 hyanantha Exp $ */ #include php.h #include php_globals.h @@ -35,6 +35,14 @@ #include winsock.h #define O_RDONLY _O_RDONLY #include win32/param.h +#elif defined(NETWARE) +/*#include ws2nlm.h*/ +/*#include sys/socket.h*/ +#ifdef NEW_LIBC +#include sys/param.h +#else +#include netware/param.h +#endif #else #include sys/param.h #endif @@ -48,6 +56,9 @@ #ifdef PHP_WIN32 #include winsock.h +#elif defined(NETWARE) defined(USE_WINSOCK) +/*#include ws2nlm.h*/ +#include novsock2.h #else #include netinet/in.h #include netdb.h @@ -56,7 +67,7 @@ #endif #endif -#if defined(PHP_WIN32) || defined(__riscos__) +#if defined(PHP_WIN32) || defined(__riscos__) || defined(NETWARE) #undef AF_UNIX #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard http_fopen_wrapper.c
hyanantha Thu Oct 24 07:16:10 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard http_fopen_wrapper.c Log: NetWare related changes/modifications. Index: php4/ext/standard/http_fopen_wrapper.c diff -u php4/ext/standard/http_fopen_wrapper.c:1.23.2.2 php4/ext/standard/http_fopen_wrapper.c:1.23.2.3 --- php4/ext/standard/http_fopen_wrapper.c:1.23.2.2 Wed Jul 10 22:41:52 2002 +++ php4/ext/standard/http_fopen_wrapper.c Thu Oct 24 07:16:10 2002 @@ -17,7 +17,7 @@ | Hartmut Holzgraefe [EMAIL PROTECTED] | +--+ */ -/* $Id: http_fopen_wrapper.c,v 1.23.2.2 2002/07/11 02:41:52 sniper Exp $ */ +/* $Id: http_fopen_wrapper.c,v 1.23.2.3 2002/10/24 11:16:10 hyanantha Exp $ */ #include php.h #include php_globals.h @@ -35,6 +35,14 @@ #include winsock.h #define O_RDONLY _O_RDONLY #include win32/param.h +#elif defined(NETWARE) +/*#include ws2nlm.h*/ +/*#include sys/socket.h*/ +#ifdef NEW_LIBC +#include sys/param.h +#else +#include netware/param.h +#endif #else #include sys/param.h #endif @@ -48,6 +56,9 @@ #ifdef PHP_WIN32 #include winsock.h +#elif defined(NETWARE) defined(USE_WINSOCK) +/*#include ws2nlm.h*/ +#include novsock2.h #else #include netinet/in.h #include netdb.h @@ -56,7 +67,7 @@ #endif #endif -#if defined(PHP_WIN32) || defined(__riscos__) +#if defined(PHP_WIN32) || defined(__riscos__) || defined(NETWARE) #undef AF_UNIX #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard head.c
hyanantha Thu Oct 24 07:16:25 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard head.c Log: NetWare related changes/modifications. Index: php4/ext/standard/head.c diff -u php4/ext/standard/head.c:1.55.2.1 php4/ext/standard/head.c:1.55.2.2 --- php4/ext/standard/head.c:1.55.2.1 Wed Jul 24 06:03:49 2002 +++ php4/ext/standard/head.cThu Oct 24 07:16:25 2002 @@ -15,9 +15,14 @@ | Author: Rasmus Lerdorf [EMAIL PROTECTED]| +--+ */ -/* $Id: head.c,v 1.55.2.1 2002/07/24 10:03:49 derick Exp $ */ +/* $Id: head.c,v 1.55.2.2 2002/10/24 11:16:25 hyanantha Exp $ */ #include stdio.h + +#if defined(NETWARE) !defined(NEW_LIBC) +#include sys/socket.h +#endif + #include php.h #include ext/standard/php_standard.h #include SAPI.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard html.c
hyanantha Thu Oct 24 07:16:38 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard html.c Log: NetWare related changes/modifications. Index: php4/ext/standard/html.c diff -u php4/ext/standard/html.c:1.41.2.1 php4/ext/standard/html.c:1.41.2.2 --- php4/ext/standard/html.c:1.41.2.1 Wed Mar 20 11:08:04 2002 +++ php4/ext/standard/html.cThu Oct 24 07:16:38 2002 -18,7 +18,7 +--+ */ -/* $Id: html.c,v 1.41.2.1 2002/03/20 16:08:04 sesser Exp $ */ +/* $Id: html.c,v 1.41.2.2 2002/10/24 11:16:38 hyanantha Exp $ */ #include php.h #include reg.h -451,8 +451,8 if (matches_map){ new[len++] = ''; - strcpy(new + len, rep); - len += strlen(rep); + strcpy(new + len, (const char*)rep);/* +Type-casting done due to NetWare */ + len += strlen((const char*)rep);/* +Type-casting done due to NetWare */ new[len++] = ';'; } } -503,7 +503,7 return; } - new = php_escape_html_entities(str, str_len, len, all, quote_style, hint_charset); + new = php_escape_html_entities((unsigned char*)str, str_len, len, all, +quote_style, hint_charset); /* Type-casting done due to NetWare */ RETVAL_STRINGL(new, len, 0); } /* }}} */ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard image.c
hyanantha Thu Oct 24 07:16:57 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard image.c Log: NetWare related changes/modifications. Index: php4/ext/standard/image.c diff -u php4/ext/standard/image.c:1.44.2.2 php4/ext/standard/image.c:1.44.2.3 --- php4/ext/standard/image.c:1.44.2.2 Tue Mar 12 00:57:28 2002 +++ php4/ext/standard/image.c Thu Oct 24 07:16:57 2002 @@ -16,7 +16,7 @@ | Marcus Boerger [EMAIL PROTECTED] | +--+ */ -/* $Id: image.c,v 1.44.2.2 2002/03/12 05:57:28 helly Exp $ */ +/* $Id: image.c,v 1.44.2.3 2002/10/24 11:16:57 hyanantha Exp $ */ /* * Based on Daniel Schmitt's imageinfo.c which carried the following * Copyright notice. @@ -39,6 +39,11 @@ #include php.h #include stdio.h + +#if defined(NETWARE) !defined(NEW_LIBC) +#include sys/socket.h +#endif + #if HAVE_FCNTL_H #include fcntl.h #endif @@ -82,10 +87,10 @@ FP_FREAD(temp, 3, socketd, fp, issock); /* fseek(fp, 6L, SEEK_SET); */ - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char*)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, +fp); */ /* Type-casting done due to NetWare */ result-width = (unsigned short)a[0] | (((unsigned short)a[1])8); - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char *)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, +fp); */ /* Type-casting done due to NetWare */ result-height = (unsigned short)a[0] | (((unsigned short)a[1])8); return result; @@ -104,7 +109,7 @@ result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); FP_FREAD(temp, sizeof(temp), socketd, fp, issock); - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) { + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) {/* +Type-casting done due to NetWare */ in_height = 0; in_width = 0; } else { @@ -169,7 +174,7 @@ result = (struct gfxinfo *) ecalloc (1, sizeof (struct gfxinfo)); FP_FREAD(temp, 5, socketd, fp, issock); /* fseek(fp, 8L, SEEK_SET); */ - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char *)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, +fp); */ /* Type-casting done due to NetWare */ bits = php_swf_get_bits (a, 0, 5); result-width = (php_swf_get_bits (a, 5 + bits, bits) - php_swf_get_bits (a, 5, bits)) / 20; @@ -192,7 +197,7 @@ FP_FREAD(temp, sizeof(temp), socketd, fp, issock); /* fseek(fp, 16L, SEEK_SET); */ - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) { + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) {/* +Type-casting done due to NetWare */ in_width = 0; in_height = 0; } else { @@ -249,8 +254,7 @@ unsigned char a[2]; /* just return 0 if we hit the end-of-file */ - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) return 0; - + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) return 0; + /* Type-casting done due to NetWare */ return (((unsigned short) a[ 0 ]) 8) + ((unsigned short) a[ 1 ]); } /* }}} */ @@ -316,16 +320,16 @@ buffer = emalloc(length); if ( !buffer) return; - if (FP_FREAD(buffer, (long) length, socketd, fp, issock) = 0) { + if (FP_FREAD((char *)buffer, (long) length, socketd, fp, issock) = 0) { + /* Type-casting done due to NetWare */ efree(buffer); return; } - sprintf(markername, APP%d, marker - M_APP0); + sprintf((char *)markername, APP%d, marker - M_APP0); /* Type-casting done +due to NetWare */ - if (zend_hash_find(Z_ARRVAL_P(info), markername, strlen(markername)+1, (void **) tmp) == FAILURE) { + if (zend_hash_find(Z_ARRVAL_P(info), (char *)markername, strlen((char +*)markername)+1, (void **) tmp) == FAILURE) {/* Type-casting done due to NetWare +*/ /* XXX we onyl catch the 1st tag of it's kind! */ - add_assoc_stringl(info, markername, buffer, length, 1); + add_assoc_stringl(info, (char *)markername, (char *)buffer, length, +1); /* Type-casting done due to NetWare */ } efree(buffer); @@ -362,7 +366,7 @@ result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); length = php_read2(socketd, fp, issock); result-bits = FP_FGETC(socketd, fp, issock); - FP_FREAD(a, sizeof(a), socketd, fp, issock); +
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard info.c
hyanantha Thu Oct 24 07:17:13 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard info.c Log: NetWare related changes/modifications. Index: php4/ext/standard/info.c diff -u php4/ext/standard/info.c:1.167.2.1 php4/ext/standard/info.c:1.167.2.2 --- php4/ext/standard/info.c:1.167.2.1 Thu Mar 14 13:39:37 2002 +++ php4/ext/standard/info.cThu Oct 24 07:17:13 2002 -17,7 +17,7 +--+ */ -/* $Id: info.c,v 1.167.2.1 2002/03/14 18:39:37 zeev Exp $ */ +/* $Id: info.c,v 1.167.2.2 2002/10/24 11:17:13 hyanantha Exp $ */ #include php.h #include php_ini.h -28,11 +28,15 #include SAPI.h #include time.h #include php_main.h -#if !defined(PHP_WIN32) +#if !defined(PHP_WIN32) !defined(NETWARE) #include build-defs.h #endif #include zend_globals.h /* needs ELS */ #include zend_highlight.h + +/*#ifdef NETWARE*/ +/*#include netware/env.h*/ /* Temporary */ +/*#endif*/ #define SECTION(name) PUTS(h2 align=\center\ name /h2\n) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard iptc.c
hyanantha Thu Oct 24 07:17:37 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard iptc.c Log: NetWare related changes/modifications. Index: php4/ext/standard/iptc.c diff -u php4/ext/standard/iptc.c:1.37 php4/ext/standard/iptc.c:1.37.2.1 --- php4/ext/standard/iptc.c:1.37 Thu Feb 28 03:26:46 2002 +++ php4/ext/standard/iptc.cThu Oct 24 07:17:37 2002 -16,7 +16,7 +--+ */ -/* $Id: iptc.c,v 1.37 2002/02/28 08:26:46 sebastian Exp $ */ +/* $Id: iptc.c,v 1.37.2.1 2002/10/24 11:17:37 hyanantha Exp $ */ /* * Functions to parse compse IPTC data. -184,7 +184,11 unsigned int marker; unsigned int spool = 0, done = 0, inx, len; unsigned char *spoolbuf=0, *poi=0; +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) +struct stat_libc sb; +#else struct stat sb; +#endif switch(ZEND_NUM_ARGS()){ case 3: -222,9 +226,15 len = Z_STRLEN_PP(iptcdata); if (spool 2) { +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) + fstat(fileno(fp), ((struct stat*)sb)); + + poi = spoolbuf = emalloc(len + sizeof(psheader) + ((struct +stat*)sb)-st_size + 1024); +#else fstat(fileno(fp), sb); poi = spoolbuf = emalloc(len + sizeof(psheader) + sb.st_size + 1024); +#endif if (! spoolbuf) { fclose(fp); -293,7 +303,7 fclose(fp); if (spool 2) { - RETVAL_STRINGL(spoolbuf, poi - spoolbuf, 0); + RETVAL_STRINGL((char*)spoolbuf, poi - spoolbuf, 0); /* +Type-casting done due to NetWare */ } else { RETURN_TRUE; } -317,7 +327,7 inx = 0; length = Z_STRLEN_PP(str); - buffer = Z_STRVAL_PP(str); + buffer = (unsigned char *)Z_STRVAL_PP(str); /* Type-casting done due to +NetWare */ inheader = 0; /* have we already found the IPTC-Header??? */ tagsfound = 0; /* number of tags already found */ -350,7 +360,7 inx += 2; } - sprintf(key, %d#%03d, (unsigned int) dataset, (unsigned int) recnum); + sprintf((char*)key, %d#%03d, (unsigned int) dataset, (unsigned int) +recnum); /* Type-casting done due to NetWare */ if ((len length) || (inx + len) length) break; -362,7 +372,7 } } - if (zend_hash_find(Z_ARRVAL_P(return_value), key, strlen(key) + 1, (void **) element) == FAILURE) { + if (zend_hash_find(Z_ARRVAL_P(return_value), (char*)key, +strlen((char*)key) + 1, (void **) element) == FAILURE) { /* Type-casting done +due to NetWare */ ALLOC_ZVAL(values); INIT_PZVAL(values); if (array_init(values) == FAILURE) { -370,10 +380,10 RETURN_FALSE; } - zend_hash_update(Z_ARRVAL_P(return_value), key, strlen(key)+1, (void *) values, sizeof(pval*), (void **) element); - } - - add_next_index_stringl(*element, buffer+inx, len, 1); + zend_hash_update(Z_ARRVAL_P(return_value), (char*)key, +strlen((char*)key)+1, (void *) values, sizeof(pval*), (void **) element); /* +Type-casting done due to NetWare */ + } + + add_next_index_stringl(*element, (char*)(buffer+inx), len, 1); /* +Type-casting done due to NetWare */ inx += len; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard lcg.c
hyanantha Thu Oct 24 07:17:53 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard lcg.c Log: NetWare related changes/modifications. Index: php4/ext/standard/lcg.c diff -u php4/ext/standard/lcg.c:1.32 php4/ext/standard/lcg.c:1.32.2.1 --- php4/ext/standard/lcg.c:1.32Thu Feb 28 03:26:46 2002 +++ php4/ext/standard/lcg.c Thu Oct 24 07:17:52 2002 -16,7 +16,7 +--+ */ -/* $Id: lcg.c,v 1.32 2002/02/28 08:26:46 sebastian Exp $ */ +/* $Id: lcg.c,v 1.32.2.1 2002/10/24 11:17:52 hyanantha Exp $ */ #include php.h #include php_lcg.h -27,6 +27,12 #ifdef PHP_WIN32 #include win32/time.h +#elif defined(NETWARE) +#ifdef NEW_LIBC +#include sys/timeval.h +#else +#include netware/time_nw.h +#endif #else #include sys/time.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard image.c
On Thu, 24 Oct 2002, Anantha Kesari H Y wrote: hyanantha Thu Oct 24 07:16:57 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standardimage.c Log: NetWare related changes/modifications. You can also commit all files in one run ... please :) Derick Index: php4/ext/standard/image.c diff -u php4/ext/standard/image.c:1.44.2.2 php4/ext/standard/image.c:1.44.2.3 --- php4/ext/standard/image.c:1.44.2.2Tue Mar 12 00:57:28 2002 +++ php4/ext/standard/image.c Thu Oct 24 07:16:57 2002 @@ -16,7 +16,7 @@ | Marcus Boerger [EMAIL PROTECTED] | +--+ */ -/* $Id: image.c,v 1.44.2.2 2002/03/12 05:57:28 helly Exp $ */ +/* $Id: image.c,v 1.44.2.3 2002/10/24 11:16:57 hyanantha Exp $ */ /* * Based on Daniel Schmitt's imageinfo.c which carried the following * Copyright notice. @@ -39,6 +39,11 @@ #include php.h #include stdio.h + +#if defined(NETWARE) !defined(NEW_LIBC) +#include sys/socket.h +#endif + #if HAVE_FCNTL_H #include fcntl.h #endif @@ -82,10 +87,10 @@ FP_FREAD(temp, 3, socketd, fp, issock); /* fseek(fp, 6L, SEEK_SET); */ - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char*)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ /* Type-casting done due to NetWare */ result-width = (unsigned short)a[0] | (((unsigned short)a[1])8); - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char *)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ /* Type-casting done due to NetWare */ result-height = (unsigned short)a[0] | (((unsigned short)a[1])8); return result; @@ -104,7 +109,7 @@ result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); FP_FREAD(temp, sizeof(temp), socketd, fp, issock); - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) { + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) {/* Type-casting done due to NetWare */ in_height = 0; in_width = 0; } else { @@ -169,7 +174,7 @@ result = (struct gfxinfo *) ecalloc (1, sizeof (struct gfxinfo)); FP_FREAD(temp, 5, socketd, fp, issock); /* fseek(fp, 8L, SEEK_SET); */ - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char *)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ /* Type-casting done due to NetWare */ bits = php_swf_get_bits (a, 0, 5); result-width = (php_swf_get_bits (a, 5 + bits, bits) - php_swf_get_bits (a, 5, bits)) / 20; @@ -192,7 +197,7 @@ FP_FREAD(temp, sizeof(temp), socketd, fp, issock); /* fseek(fp, 16L, SEEK_SET); */ - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) { + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) {/* Type-casting done due to NetWare */ in_width = 0; in_height = 0; } else { @@ -249,8 +254,7 @@ unsigned char a[2]; /* just return 0 if we hit the end-of-file */ - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) return 0; - + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) return 0; /* Type-casting done due to NetWare */ return (((unsigned short) a[ 0 ]) 8) + ((unsigned short) a[ 1 ]); } /* }}} */ @@ -316,16 +320,16 @@ buffer = emalloc(length); if ( !buffer) return; - if (FP_FREAD(buffer, (long) length, socketd, fp, issock) = 0) { + if (FP_FREAD((char *)buffer, (long) length, socketd, fp, issock) = 0) { /* Type-casting done due to NetWare */ efree(buffer); return; } - sprintf(markername, APP%d, marker - M_APP0); + sprintf((char *)markername, APP%d, marker - M_APP0); /* Type-casting done due to NetWare */ - if (zend_hash_find(Z_ARRVAL_P(info), markername, strlen(markername)+1, (void **) tmp) == FAILURE) { + if (zend_hash_find(Z_ARRVAL_P(info), (char *)markername, strlen((char *)markername)+1, (void **) tmp) == FAILURE) {/* Type-casting done due to NetWare */ /* XXX we onyl catch the 1st tag of it's kind! */ - add_assoc_stringl(info, markername, buffer, length, 1); + add_assoc_stringl(info, (char *)markername, (char *)buffer, length, 1); /* Type-casting done due to NetWare */ } efree(buffer); @@ -362,7 +366,7 @@ result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); length = php_read2(socketd, fp, issock); result-bits = FP_FGETC(socketd, fp, issock); -
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard link.c
hyanantha Thu Oct 24 07:18:06 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard link.c Log: NetWare related changes/modifications. Index: php4/ext/standard/link.c diff -u php4/ext/standard/link.c:1.37.2.1 php4/ext/standard/link.c:1.37.2.2 --- php4/ext/standard/link.c:1.37.2.1 Sun Jun 23 13:18:17 2002 +++ php4/ext/standard/link.cThu Oct 24 07:18:06 2002 -16,7 +16,7 +--+ */ -/* $Id: link.c,v 1.37.2.1 2002/06/23 17:18:17 sesser Exp $ */ +/* $Id: link.c,v 1.37.2.2 2002/10/24 11:18:06 hyanantha Exp $ */ #include php.h #include php_filestat.h -33,6 +33,8 #if HAVE_PWD_H #ifdef PHP_WIN32 #include win32/pwd.h +#elif defined(NETWARE) +#include netware/pwd.h #else #include pwd.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard mail.c
hyanantha Thu Oct 24 07:18:24 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard mail.c Log: NetWare related changes/modifications. Index: php4/ext/standard/mail.c diff -u php4/ext/standard/mail.c:1.48.2.3 php4/ext/standard/mail.c:1.48.2.4 --- php4/ext/standard/mail.c:1.48.2.3 Sat Aug 24 07:38:13 2002 +++ php4/ext/standard/mail.cThu Oct 24 07:18:24 2002 -16,14 +16,14 +--+ */ -/* $Id: mail.c,v 1.48.2.3 2002/08/24 11:38:13 sesser Exp $ */ +/* $Id: mail.c,v 1.48.2.4 2002/10/24 11:18:24 hyanantha Exp $ */ #include stdlib.h #include ctype.h #include stdio.h #include php.h #include ext/standard/info.h -#if !defined(PHP_WIN32) +#if !defined(PHP_WIN32) !defined(NETWARE) #include build-defs.h #if HAVE_SYSEXITS_H #include sysexits.h -42,6 +42,12 #include win32/sendmail.h #endif +/* Additional headers for NetWare */ +#ifdef NETWARE +#include netware/pipe.h/* For popen(), pclose() */ +#include netware/sysexits.h /* For exit status codes like EX_OK */ +#endif + /* {{{ proto int ezmlm_hash(string addr) Calculate EZMLM list hash value. */ PHP_FUNCTION(ezmlm_hash) -128,7 +134,7 */ PHPAPI int php_mail(char *to, char *subject, char *message, char *headers, char *extra_cmd) { -#ifdef PHP_WIN32 +#if (defined PHP_WIN32) || (defined NETWARE) int tsm_err; #endif FILE *sendmail; -137,10 +143,10 char *sendmail_cmd = NULL; if (!sendmail_path) { -#ifdef PHP_WIN32 +#if (defined PHP_WIN32) || (defined NETWARE) /* handle old style win smtp sending */ if (TSendMail(INI_STR(SMTP), tsm_err, headers, subject, to, message) != SUCCESS){ - php_error(E_WARNING, GetSMErrorText(tsm_err)); + php_error(E_WARNING, (const char *)GetSMErrorText(tsm_err)); + /* Type-casting done due to NetWare */ return 0; } return 1; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard math.c
hyanantha Thu Oct 24 07:18:40 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard math.c Log: NetWare related changes/modifications. Index: php4/ext/standard/math.c diff -u php4/ext/standard/math.c:1.80.2.4 php4/ext/standard/math.c:1.80.2.5 --- php4/ext/standard/math.c:1.80.2.4 Mon Jun 24 04:18:54 2002 +++ php4/ext/standard/math.cThu Oct 24 07:18:40 2002 -19,7 +19,7 +--+ */ -/* $Id: math.c,v 1.80.2.4 2002/06/24 08:18:54 derick Exp $ */ +/* $Id: math.c,v 1.80.2.5 2002/10/24 11:18:40 hyanantha Exp $ */ #include php.h #include php_math.h -314,7 +314,7 /* }}} */ -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) /* {{{ proto float asinh(float number) Returns the inverse hyperbolic sine of the number, i.e. the value whose hyperbolic sine is number */ -471,7 +471,7 /* }}} */ -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) /* {{{ proto float expm1(float number) Returns exp(number) - 1, computed in a way that accurate even when the value of number is close to zero */ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard microtime.c
hyanantha Thu Oct 24 07:19:14 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard microtime.c Log: NetWare related changes/modifications. Index: php4/ext/standard/microtime.c diff -u php4/ext/standard/microtime.c:1.36 php4/ext/standard/microtime.c:1.36.2.1 --- php4/ext/standard/microtime.c:1.36 Thu Feb 28 03:26:46 2002 +++ php4/ext/standard/microtime.c Thu Oct 24 07:19:14 2002 -16,7 +16,7 +--+ */ -/* $Id: microtime.c,v 1.36 2002/02/28 08:26:46 sebastian Exp $ */ +/* $Id: microtime.c,v 1.36.2.1 2002/10/24 11:19:14 hyanantha Exp $ */ #include php.h -25,6 +25,12 #endif #ifdef PHP_WIN32 #include win32/time.h +#elif defined(NETWARE) +#ifdef NEW_LIBC +#include sys/timeval.h +#else +#include netware/time_nw.h +#endif #else #include sys/time.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard pack.c
hyanantha Thu Oct 24 07:19:29 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard pack.c Log: NetWare related changes/modifications. Index: php4/ext/standard/pack.c diff -u php4/ext/standard/pack.c:1.37.2.1 php4/ext/standard/pack.c:1.37.2.2 --- php4/ext/standard/pack.c:1.37.2.1 Sat Aug 17 12:47:54 2002 +++ php4/ext/standard/pack.cThu Oct 24 07:19:29 2002 @@ -15,7 +15,7 @@ | Author: Chris Schneider [EMAIL PROTECTED] | +--+ */ -/* $Id: pack.c,v 1.37.2.1 2002/08/17 16:47:54 iliaa Exp $ */ +/* $Id: pack.c,v 1.37.2.2 2002/10/24 11:19:29 hyanantha Exp $ */ #include php.h @@ -30,6 +30,18 @@ #include winsock.h #define O_RDONLY _O_RDONLY #include win32/param.h +#elif defined(NETWARE) +#ifdef USE_WINSOCK +/*#include ws2nlm.h*/ +#include novsock2.h +#else +#include sys/socket.h +#endif +#ifdef NEW_LIBC +#include sys/param.h +#else +#include netware/param.h +#endif #else #include sys/param.h #endif @@ -40,6 +52,8 @@ #if HAVE_PWD_H #ifdef PHP_WIN32 #include win32/pwd.h +#elif defined(NETWARE) +#include netware/pwd.h #else #include pwd.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard pageinfo.c
hyanantha Thu Oct 24 07:19:43 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard pageinfo.c Log: NetWare related changes/modifications. Index: php4/ext/standard/pageinfo.c diff -u php4/ext/standard/pageinfo.c:1.30 php4/ext/standard/pageinfo.c:1.30.2.1 --- php4/ext/standard/pageinfo.c:1.30 Thu Feb 28 03:26:46 2002 +++ php4/ext/standard/pageinfo.cThu Oct 24 07:19:43 2002 -16,7 +16,7 +--+ */ -/* $Id: pageinfo.c,v 1.30 2002/02/28 08:26:46 sebastian Exp $ */ +/* $Id: pageinfo.c,v 1.30.2.1 2002/10/24 11:19:43 hyanantha Exp $ */ #include php.h #include pageinfo.h -27,6 +27,11 #if HAVE_PWD_H #ifdef PHP_WIN32 #include win32/pwd.h +#elif defined(NETWARE) +#ifdef ZTS +extern int basic_globals_id; +#endif +#include netware/pwd.h #else #include pwd.h #endif -45,7 +50,11 */ PHPAPI void php_statpage(TSRMLS_D) { +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) + struct stat_libc *pstat; +#else struct stat *pstat; +#endif pstat = sapi_get_stat(TSRMLS_C); -54,7 +63,11 BG(page_uid) = pstat-st_uid; BG(page_gid) = pstat-st_gid; BG(page_inode) = pstat-st_ino; +#if defined(NETWARE) defined(NEW_LIBC) + BG(page_mtime) = (pstat-st_mtime).tv_nsec; +#else BG(page_mtime) = pstat-st_mtime; +#endif } } } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard string.c
hyanantha Thu Oct 24 07:20:21 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard string.c Log: NetWare related changes/modifications. Index: php4/ext/standard/string.c diff -u php4/ext/standard/string.c:1.263.2.6 php4/ext/standard/string.c:1.263.2.7 --- php4/ext/standard/string.c:1.263.2.6Mon Jun 24 04:19:43 2002 +++ php4/ext/standard/string.c Thu Oct 24 07:20:21 2002 -18,7 +18,7 +--+ */ -/* $Id: string.c,v 1.263.2.6 2002/06/24 08:19:43 derick Exp $ */ +/* $Id: string.c,v 1.263.2.7 2002/10/24 11:20:21 hyanantha Exp $ */ /* Synced with php 3.0 revision 1.193 1999-06-16 [ssb] */ -105,9 +105,9 register unsigned char *result = NULL; size_t i, j; - result = (char *) emalloc(oldlen * 2 * sizeof(char) + 1); + result = (unsigned char*) emalloc(oldlen * 2 * sizeof(char) + 1); /* +Type-casting done due to NetWare */ if(!result) { - return result; + return (char*)result; /* Type-casting done due to NetWare */ } for(i = j = 0; i oldlen; i++) { -119,7 +119,7 if (newlen) *newlen = oldlen * 2 * sizeof(char); - return result; + return (char *)result; /* Type-casting done due to NetWare */ } /* }}} */ -183,7 +183,7 } convert_to_string_ex(data); - result = php_bin2hex(Z_STRVAL_PP(data), Z_STRLEN_PP(data), newlen); + result = php_bin2hex((const unsigned char*)Z_STRVAL_PP(data), +Z_STRLEN_PP(data), newlen); /* Type-casting done due to NetWare */ if (!result) { RETURN_FALSE; -514,9 +514,9 char mask[256]; if (what) { - php_charmask(Z_STRVAL_PP(what), Z_STRLEN_PP(what), mask TSRMLS_CC); + php_charmask((unsigned char*)Z_STRVAL_PP(what), Z_STRLEN_PP(what), +mask TSRMLS_CC); /* Type-casting done due to NetWare */ } else { - php_charmask( \n\r\t\v\0, 6, mask TSRMLS_CC); + php_charmask((unsigned char*) \n\r\t\v\0, 6, mask TSRMLS_CC); /* +Type-casting done due to NetWare */ } if (mode 1) { -1238,9 +1238,9 PHPAPI char *php_stristr(unsigned char *s, unsigned char *t, size_t s_len, size_t t_len) { - php_strtolower(s, s_len); - php_strtolower(t, t_len); - return php_memnstr(s, t, t_len, s + s_len); + php_strtolower((char*)s, s_len);/* Type-casting done due to NetWare */ + php_strtolower((char*)t, t_len);/* Type-casting done due to NetWare */ + return php_memnstr((char*)s, (char*)t, t_len, (char*)(s + s_len)); /* +Type-casting done due to NetWare */ } /* }}} */ -1313,7 +1313,7 RETURN_FALSE; } - found = php_stristr(Z_STRVAL_PP(haystack), Z_STRVAL_PP(needle), + found = php_stristr((unsigned char*)Z_STRVAL_PP(haystack), (unsigned +char*)Z_STRVAL_PP(needle), /* Type-casting done due to NetWare */ Z_STRLEN_PP(haystack), Z_STRLEN_PP(needle)); } else { -1321,7 +1321,7 needle_char[0] = (char) Z_LVAL_PP(needle); needle_char[1] = 0; - found = php_stristr(Z_STRVAL_PP(haystack), needle_char, + found = php_stristr((unsigned char*)Z_STRVAL_PP(haystack), (unsigned +char*)needle_char, /* Type-casting done due to NetWare */ Z_STRLEN_PP(haystack), 1); } -2367,7 +2367,7 length = strlen(str); } - php_charmask(what, wlength, flags TSRMLS_CC); + php_charmask((unsigned char*)what, wlength, flags TSRMLS_CC); /* +Type-casting done due to NetWare */ for (source=str, end=source+length, target=new_str; (c=*source) || sourceend; source++) { if (flags[(unsigned char)c]) { -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard syslog.c
hyanantha Thu Oct 24 07:21:43 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard syslog.c Log: NetWare related changes/modifications. Index: php4/ext/standard/syslog.c diff -u php4/ext/standard/syslog.c:1.38 php4/ext/standard/syslog.c:1.38.2.1 --- php4/ext/standard/syslog.c:1.38 Thu Feb 28 03:26:49 2002 +++ php4/ext/standard/syslog.c Thu Oct 24 07:21:42 2002 -16,7 +16,7 +--+ */ -/* $Id: syslog.c,v 1.38 2002/02/28 08:26:49 sebastian Exp $ */ +/* $Id: syslog.c,v 1.38.2.1 2002/10/24 11:21:42 hyanantha Exp $ */ #include php.h -75,7 +75,7 /* AIX doesn't have LOG_AUTHPRIV */ REGISTER_LONG_CONSTANT(LOG_AUTHPRIV, LOG_AUTHPRIV, CONST_CS | CONST_PERSISTENT); #endif -#if !defined(PHP_WIN32) +#if !defined(PHP_WIN32) !defined(NETWARE) REGISTER_LONG_CONSTANT(LOG_LOCAL0, LOG_LOCAL0, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT(LOG_LOCAL1, LOG_LOCAL1, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT(LOG_LOCAL2, LOG_LOCAL2, CONST_CS | CONST_PERSISTENT); -159,7 +159,7 /* AIX doesn't have LOG_AUTHPRIV */ SET_VAR_LONG(LOG_AUTHPRIV, LOG_AUTHPRIV); #endif -#if !defined(PHP_WIN32) +#if !defined(PHP_WIN32) !defined(NETWARE) SET_VAR_LONG(LOG_LOCAL0, LOG_LOCAL0); SET_VAR_LONG(LOG_LOCAL1, LOG_LOCAL1); SET_VAR_LONG(LOG_LOCAL2, LOG_LOCAL2); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard var_unserializer.c
hyanantha Thu Oct 24 07:22:11 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standard var_unserializer.c Log: NetWare related changes/modifications. Index: php4/ext/standard/var_unserializer.c diff -u php4/ext/standard/var_unserializer.c:1.6.2.3 php4/ext/standard/var_unserializer.c:1.6.2.4 --- php4/ext/standard/var_unserializer.c:1.6.2.3Tue Aug 20 15:45:44 2002 +++ php4/ext/standard/var_unserializer.cThu Oct 24 07:22:11 2002 -217,7 +217,12 PHPAPI int php_var_unserialize(UNSERIALIZE_PARAMETER) { +#ifndef NETWARE const unsigned char *cursor, *limit, *marker, *start; +#else + const char *cursor, *start; + const char *limit=NULL, *marker=NULL; +#endif /* NETWARE */ zval **rval_ref; cursor = *p; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/xml xml.c
hyanantha Thu Oct 24 07:22:43 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/xml xml.c Log: NetWare related changes/modifications. Index: php4/ext/xml/xml.c diff -u php4/ext/xml/xml.c:1.104 php4/ext/xml/xml.c:1.104.2.1 --- php4/ext/xml/xml.c:1.104Thu Feb 28 03:26:57 2002 +++ php4/ext/xml/xml.c Thu Oct 24 07:22:42 2002 -17,7 +17,7 +--+ */ -/* $Id: xml.c,v 1.104 2002/02/28 08:26:57 sebastian Exp $ */ +/* $Id: xml.c,v 1.104.2.1 2002/10/24 11:22:42 hyanantha Exp $ */ #define IS_EXT_MODULE -35,7 +35,7 #if HAVE_LIBEXPAT -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) # include build-defs.h # endif # include ext/standard/head.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /ext/xml/expat xmltok_impl.c
hyanantha Thu Oct 24 07:23:11 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/xml/expat xmltok_impl.c Log: NetWare related changes/modifications. Index: php4/ext/xml/expat/xmltok_impl.c diff -u php4/ext/xml/expat/xmltok_impl.c:1.1 php4/ext/xml/expat/xmltok_impl.c:1.1.4.1 --- php4/ext/xml/expat/xmltok_impl.c:1.1Fri May 11 13:57:35 2001 +++ php4/ext/xml/expat/xmltok_impl.cThu Oct 24 07:23:11 2002 -3,6 +3,11 See the file COPYING for copying permission. */ +#ifdef NETWARE /* Check whether these two files are really required for NetWare */ +#include xmltok.h +#include xmltok_impl.h +#endif + #include php_compat.h #ifndef IS_INVALID_CHAR -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main config.nw.h
hyanantha Thu Oct 24 07:24:10 2002 EDT Added files: (Branch: PHP_4_2_0) /php4/main config.nw.h Log: NetWare related file. Index: php4/main/config.nw.h +++ php4/main/config.nw.h /* config.nw.h. Configure file for NetWare platform */ / Need to carefully look into each constant and either define or undef it w.r.t. NetWare. / /* Define if PHP to setup it's own SIGCHLD handler (not needed on NetWare) */ #define PHP_SIGCHILD 0 /* dns functions found in resolv.lib */ #define HAVE_LIBBIND 1 #define HAVE_GETSERVBYNAME 1 #define HAVE_GETSERVBYPORT 1 #define HAVE_GETPROTOBYNAME 1 #define HAVE_GETPROTOBYNUMBER 1 /* set to enable bcmath */ #define WITH_BCMATH 1 /* set to enable mysql */ #define HAVE_MYSQL 1 /* set to enable FTP support */ #define HAVE_FTP 1 /* set to enable bundled PCRE library */ #define HAVE_BUNDLED_PCRE 1 /* set to enable bundled expat library */ /* #define HAVE_LIBEXPAT 1 */ /* For now */ #define HAVE_WDDX 0 /* set to enable the crypt command */ /* #define HAVE_CRYPT 1 */ /* #define HAVE_CRYPT_H 1 */ /* set to enable force cgi redirect */ #define FORCE_CGI_REDIRECT 0 /* should be added to runtime config*/ #define PHP_URL_FOPEN 1 #define STDIN_FILENO 0 #define STDOUT_FILENO 1 #define STDERR_FILENO 2 /* The following are defaults for run-time configuration ---*/ #define PHP_SAFE_MODE 0 #define MAGIC_QUOTES 0 /* This is the default configuration file to read */ #define CONFIGURATION_FILE_PATH php.ini #define USE_CONFIG_FILE 1 #define PHP_INCLUDE_PATHNULL /* Undefine if you want stricter XML/SGML compliance by default */ /* this disables ?expression? and ?=expression? */ #define DEFAULT_SHORT_OPEN_TAG 1 /* The following defines are for those modules which require external libraries to compile. These will be removed from here in a future beta, as these modules will be moved out to dll's ---*/ #define HAVE_ERRMSG_H 0 /*needed for mysql 3.21.17 and up*/ #undef HAVE_ADABAS #undef HAVE_SOLID /* The following may or may not be (or need to be) ported to the windows environment. ---*/ /* Define if you have the link function. */ #undef HAVE_LINK /* Define if you have the symlink function. */ #undef HAVE_SYMLINK /* Define if you have the usleep function. */ #undef HAVE_USLEEP #define HAVE_GETCWD 1 /* #define HAVE_POSIX_READDIR_R 1 */ /* We will use readdir() from LibC */ #define NEED_ISBLANK 1 /* The following should never need to be played with Functions defined to 0 or remarked out are either already handled by the standard VC libraries, or are no longer needed, or simply will/can not be ported. DONT TOUCH! Unless you realy know what your messing with! ---*/ #define DISCARD_PATH 0 #undef HAVE_SETITIMER #undef HAVE_IODBC #define HAVE_UODBC 1 #define HAVE_LIBDL 1 #define HAVE_SENDMAIL 1 #define HAVE_GETTIMEOFDAY 1 #define HAVE_PUTENV 1 #define HAVE_LIMITS_H 1 #define HAVE_TZSET 1 #define HAVE_TZNAME 1 /* Define if you have the flock function. */ #undef HAVE_FLOCK /* Define if you have alloca, as a function or macro. */ /* Though we have alloca(), this seems to be causing some problem with the stack pointer -- hence not using it */ /* #define HAVE_ALLOCA 1 */ /* Define if you have sys/time.h */ #undef HAVE_SYS_TIME_H /* Define if you have signal.h */ #define HAVE_SIGNAL_H 1 /* Define if your struct stat has st_blksize. */ #define HAVE_ST_BLKSIZE /* Define if your struct stat has st_blocks. */ #define HAVE_ST_BLOCKS /* Define if your struct stat has st_rdev. */ #define HAVE_ST_RDEV 1 /* Define if utime(file, NULL) sets file's timestamp to the present. */ #define HAVE_UTIME_NULL 1 /* Define if you have the vprintf function. */ #define HAVE_VPRINTF 1 /* Define if you have the ANSI C header files. */ #define STDC_HEADERS 1 /* Define both of these if you want the bundled REGEX library */ #define REGEX 1 #define HSREGEX 1 #define HAVE_PCRE 1 #define HAVE_LDAP 1 /* Define if you have the gcvt function. */ /* #define HAVE_GCVT 1 */ /* Define if you have the getlogin function. */ /* #define HAVE_GETLOGIN 1 */ /* Define if you have the gettimeofday function. */ #define HAVE_GETTIMEOFDAY 1 /* Define if you have the memcpy function. */ #define HAVE_MEMCPY 1 /* Define if you have the memmove function. */ #define HAVE_MEMMOVE 1 /* Define if you have the putenv function. */ /* #define HAVE_PUTENV 1 */ /* Why are such things defined in more
[PHP-CVS] cvs: php4(PHP_4_2_0) /main fopen_wrappers.c
hyanantha Thu Oct 24 07:24:45 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main fopen_wrappers.c Log: NetWare related changes/modifications. Index: php4/main/fopen_wrappers.c diff -u php4/main/fopen_wrappers.c:1.142.2.4 php4/main/fopen_wrappers.c:1.142.2.5 --- php4/main/fopen_wrappers.c:1.142.2.4Sat Sep 28 12:27:53 2002 +++ php4/main/fopen_wrappers.c Thu Oct 24 07:24:44 2002 @@ -16,7 +16,7 @@ | Jim Winstead [EMAIL PROTECTED] | +--+ */ -/* $Id: fopen_wrappers.c,v 1.142.2.4 2002/09/28 16:27:53 rasmus Exp $ */ +/* $Id: fopen_wrappers.c,v 1.142.2.5 2002/10/24 11:24:44 hyanantha Exp $ */ /* {{{ includes */ @@ -36,7 +36,15 @@ #include winsock.h #define O_RDONLY _O_RDONLY #include win32/param.h +#elif defined(NETWARE) +/*#include ws2nlm.h*/ +/*#include sys/socket.h*/ +#ifdef NEW_LIBC +#include sys/param.h #else +#include netware/param.h +#endif +#else /* NETWARE */ #include sys/param.h #endif @@ -49,6 +57,8 @@ #if HAVE_PWD_H #ifdef PHP_WIN32 #include win32/pwd.h +#elif defined(NETWARE) +#include netware/pwd.h #else #include pwd.h #endif @@ -65,6 +75,9 @@ #ifdef PHP_WIN32 #include winsock.h +#elif defined(NETWARE) defined(USE_WINSOCK) +/*#include ws2nlm.h*/ +#include novsock2.h #else #include netinet/in.h #include netdb.h @@ -73,7 +86,7 @@ #endif #endif -#if defined(PHP_WIN32) || defined(__riscos__) +#if defined(PHP_WIN32) || defined(__riscos__) || defined(NETWARE) #undef AF_UNIX #endif @@ -426,7 +439,11 @@ char *pathbuf, *ptr, *end; char *exec_fname; char trypath[MAXPATHLEN]; +#if defined(NETWARE) defined(CLIB_STAT_PATCH) +struct stat_libc sb; +#else struct stat sb; +#endif FILE *fp; int path_length; int filename_length; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main internal_functions_nw.c
hyanantha Thu Oct 24 07:25:42 2002 EDT Added files: (Branch: PHP_4_2_0) /php4/main internal_functions_nw.c Log: NetWare related file. Index: php4/main/internal_functions_nw.c +++ php4/main/internal_functions_nw.c -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main main.c
hyanantha Thu Oct 24 07:26:12 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main main.c Log: NetWare related changes/modifications. Index: php4/main/main.c diff -u php4/main/main.c:1.429.2.4 php4/main/main.c:1.429.2.5 --- php4/main/main.c:1.429.2.4 Tue Sep 17 07:01:05 2002 +++ php4/main/main.cThu Oct 24 07:26:12 2002 -18,7 +18,7 +--+ */ -/* $Id: main.c,v 1.429.2.4 2002/09/17 11:01:05 zeev Exp $ */ +/* $Id: main.c,v 1.429.2.5 2002/10/24 11:26:12 hyanantha Exp $ */ /* {{{ includes */ -28,6 +28,18 #include win32/time.h #include win32/signal.h #include process.h +#elif defined(NETWARE) +#ifdef NEW_LIBC +#include sys/timeval.h +#else +#include netware/time_nw.h +#endif +/*#include netware/signal_nw.h*/ +/*#include netware/env.h*//* Temporary */ +/*#include process.h*/ +#ifdef USE_WINSOCK +#include novsock2.h +#endif #else #include build-defs.h #endif -857,7 +869,7 php_core_globals *core_globals; sapi_globals_struct *sapi_globals = ts_resource(sapi_globals_id); #endif -#ifdef PHP_WIN32 +#if defined(PHP_WIN32) || (defined(NETWARE) (USE_WINSOCK)) WORD wVersionRequested = MAKEWORD(2, 0); WSADATA wsaData; #endif -923,7 +935,7 setlocale(LC_CTYPE, ); #endif -#ifdef PHP_WIN32 +#if defined(PHP_WIN32) || (defined(NETWARE) (USE_WINSOCK)) /* start up winsock services */ if (WSAStartup(wVersionRequested, wsaData) != 0) { php_printf(\nwinsock.dll unusable. %d\n, WSAGetLastError()); -1045,7 +1057,7 return; } -#ifdef PHP_WIN32 +#if defined(PHP_WIN32) || (defined(NETWARE) (USE_WINSOCK)) /*close winsock */ WSACleanup(); #endif -1421,7 +1433,7 char *pass; char *user; - user = php_base64_decode(auth + 6, strlen(auth) - 6, NULL); + user = (char*)php_base64_decode((const unsigned char*)auth + 6, +strlen(auth) - 6, NULL);/* Type-casting done due to NetWare */ if (user) { pass = strchr(user, ':'); if (pass) { -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php.h
hyanantha Thu Oct 24 07:27:24 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php.h Log: NetWare related changes/modifications. Index: php4/main/php.h diff -u php4/main/php.h:1.159 php4/main/php.h:1.159.2.1 --- php4/main/php.h:1.159 Thu Feb 28 19:16:58 2002 +++ php4/main/php.h Thu Oct 24 07:27:23 2002 -17,7 +17,7 +--+ */ -/* $Id: php.h,v 1.159 2002/03/01 00:16:58 shane Exp $ */ +/* $Id: php.h,v 1.159.2.1 2002/10/24 11:27:23 hyanantha Exp $ */ #ifndef PHP_H #define PHP_H -61,6 +61,13 #define PHP_DIR_SEPARATOR '/' #endif +#ifdef NETWARE +/*#include utsname.h*/ +#define PHP_UNAME NetWare/* For php_get_uname() function */ +#define PHP_OS PHP_UNAME /* This is obtained using 'uname' on Unix and assigned +in the case of Windows. + For NetWare, we'll +do it this way atleast for now */ +#endif + #include php_regex.h -171,6 +178,13 # ifdef PHP_WIN32 #include win32/pwd.h #include win32/param.h +#elif defined(NETWARE) +#ifdef NEW_LIBC +#include sys/param.h +#else +#include NetWare/param.h +#endif +#include NetWare/pwd.h # else #include pwd.h #include sys/param.h -212,7 +226,17 extern pval *data; #if !defined(PHP_WIN32) extern char **environ; +#ifdef NETWARE +#ifdef NEW_LIBC +/*#undef environ*/ /* For now, so that our 'environ' implementation is used */ #define php_sleep sleep +#else +#define php_sleep delay /* sleep() and usleep() are not available */ +#define usleep delay +#endif +#else +#define php_sleep sleep +#endif #endif #ifdef PHP_PWRITE_64 -291,7 +315,7 #include main/php_output.h #define PHPWRITE(str, str_len) php_body_write((str), (str_len) TSRMLS_CC) #define PUTS(str) php_body_write((str), strlen((str)) TSRMLS_CC) -#define PUTC(c)(php_body_write((c), 1 TSRMLS_CC), (c)) +#define PUTC(c)(php_body_write((const +char*)((c)), 1 TSRMLS_CC), (c)) /* Type-casting done due to NetWare */ #define PHPWRITE_H(str, str_len) php_header_write((str), (str_len) TSRMLS_CC) #define PUTS_H(str)php_header_write((str), strlen((str)) TSRMLS_CC) #define PUTC_H(c) (php_header_write((c), 1 TSRMLS_CC), (c)) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php_compat.h
hyanantha Thu Oct 24 07:27:39 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php_compat.h Log: NetWare related changes/modifications. Index: php4/main/php_compat.h diff -u php4/main/php_compat.h:1.10 php4/main/php_compat.h:1.10.4.1 --- php4/main/php_compat.h:1.10 Mon Jul 30 11:10:15 2001 +++ php4/main/php_compat.h Thu Oct 24 07:27:39 2002 -3,6 +3,8 #ifdef PHP_WIN32 #include config.w32.h +#elif defined(NETWARE) +# include config.nw.h #else #include php_config.h #endif -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php_ini.c
hyanantha Thu Oct 24 07:27:55 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php_ini.c Log: NetWare related changes/modifications. Index: php4/main/php_ini.c diff -u php4/main/php_ini.c:1.80 php4/main/php_ini.c:1.80.2.1 --- php4/main/php_ini.c:1.80Mon Mar 4 19:21:28 2002 +++ php4/main/php_ini.c Thu Oct 24 07:27:55 2002 -16,10 +16,10 +--+ */ -/* $Id: php_ini.c,v 1.80 2002/03/05 00:21:28 fmk Exp $ */ +/* $Id: php_ini.c,v 1.80.2.1 2002/10/24 11:27:55 hyanantha Exp $ */ #include php.h -#ifndef PHP_WIN32 +#if !defined(PHP_WIN32) !defined(NETWARE) #include build-defs.h #endif #include ext/standard/info.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php_logos.c
hyanantha Thu Oct 24 07:28:10 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php_logos.c Log: NetWare related changes/modifications. Index: php4/main/php_logos.c diff -u php4/main/php_logos.c:1.13 php4/main/php_logos.c:1.13.2.1 --- php4/main/php_logos.c:1.13 Thu Feb 28 03:27:03 2002 +++ php4/main/php_logos.c Thu Oct 24 07:28:10 2002 -84,7 +84,7 sapi_add_header(content_header, len, 1); free(content_header); - PHPWRITE(logo_image-data, logo_image-size); + PHPWRITE((const char*)logo_image-data, logo_image-size); /* +Type-casting done due to NetWare */ return 1; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php_open_temporary_file.c
hyanantha Thu Oct 24 07:28:41 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php_open_temporary_file.c Log: NetWare related changes/modifications. Index: php4/main/php_open_temporary_file.c diff -u php4/main/php_open_temporary_file.c:1.14 php4/main/php_open_temporary_file.c:1.14.2.1 --- php4/main/php_open_temporary_file.c:1.14Thu Feb 28 03:27:03 2002 +++ php4/main/php_open_temporary_file.c Thu Oct 24 07:28:40 2002 -29,6 +29,19 #define O_RDONLY _O_RDONLY #include win32/param.h #include win32/winutil.h +#elif defined(NETWARE) +#ifdef USE_WINSOCK +/*#include ws2nlm.h*/ +#include novsock2.h +#else +#include sys/socket.h +#endif +#ifdef NEW_LIBC +#include sys/param.h +#else +#include netware/param.h +#endif +#include netware/mktemp.h #else #include sys/param.h #include sys/socket.h -95,6 +108,9 #ifndef PHP_WIN32 int fd; #endif +#ifdef NETWARE +char *file_path = NULL; +#endif if (!path) { return NULL; -115,6 +131,14 #ifdef PHP_WIN32 if (GetTempFileName(path, pfx, 0, opened_path)) { fp = VCWD_FOPEN(opened_path, wb); + } else { + fp = NULL; + } +#elif defined(NETWARE) +/* Using standard mktemp() implementation for NetWare */ +file_path = mktemp(opened_path); + if (file_path) { + fp = VCWD_FOPEN(file_path, wb); } else { fp = NULL; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php_sprintf.c
hyanantha Thu Oct 24 07:29:04 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php_sprintf.c Log: NetWare related changes/modifications. Index: php4/main/php_sprintf.c diff -u php4/main/php_sprintf.c:1.12 php4/main/php_sprintf.c:1.12.2.1 --- php4/main/php_sprintf.c:1.12Thu Feb 28 03:27:04 2002 +++ php4/main/php_sprintf.c Thu Oct 24 07:29:04 2002 -16,11 +16,15 +--+ */ -/* $Id: php_sprintf.c,v 1.12 2002/02/28 08:27:04 sebastian Exp $ */ +/* $Id: php_sprintf.c,v 1.12.2.1 2002/10/24 11:29:04 hyanantha Exp $ */ #include stdio.h #include stdarg.h +#ifndef NETWARE #include php_config.h +#else +#include config.nw.h +#endif #if PHP_BROKEN_SPRINTF -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main php_syslog.h
hyanantha Thu Oct 24 07:29:26 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main php_syslog.h Log: NetWare related changes/modifications. Index: php4/main/php_syslog.h diff -u php4/main/php_syslog.h:1.5 php4/main/php_syslog.h:1.5.8.1 --- php4/main/php_syslog.h:1.5 Sat Feb 24 16:08:15 2001 +++ php4/main/php_syslog.h Thu Oct 24 07:29:26 2002 -3,6 +3,11 #ifdef PHP_WIN32 #include win32/syslog.h +#elif defined(NETWARE) +# include config.nw.h +#ifdef HAVE_SYSLOG_H +#include syslog.h +#endif #else #include php_config.h #ifdef HAVE_SYSLOG_H -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main reentrancy.c
hyanantha Thu Oct 24 07:29:51 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main reentrancy.c Log: NetWare related changes/modifications. Index: php4/main/reentrancy.c diff -u php4/main/reentrancy.c:1.33 php4/main/reentrancy.c:1.33.2.1 --- php4/main/reentrancy.c:1.33 Thu Feb 28 03:27:04 2002 +++ php4/main/reentrancy.c Thu Oct 24 07:29:51 2002 -28,6 +28,11 #include win32/readdir.h #endif +#if defined(NETWARE) !defined(NEW_LIBC) +/*#include ws2nlm.h*/ +#include sys/socket.h +#endif + #include php_reentrancy.h #include ext/standard/php_rand.h /* for RAND_MAX */ -113,6 +118,51 } #endif + +/* + Re-entrant versions of functions seem to be better for loading NLMs in +different address space. + Since we have them now in LibC, we might as well make use of them. +*/ +#if defined(NETWARE) + +#define HAVE_LOCALTIME_R 1 +#define HAVE_CTIME_R 1 +#define HAVE_ASCTIME_R 1 +#define HAVE_GMTIME_R 1 + +PHPAPI struct tm *php_localtime_r(const time_t *const timep, struct tm *p_tm) +{ +/* Modified according to LibC definition : Venkat (1/5/02) */ + if (localtime_r(timep, p_tm) != NULL) + return (p_tm); + return (NULL); +} + +PHPAPI char *php_ctime_r(const time_t *clock, char *buf) +{ +/* Modified according to LibC definition : Venkat (30/4/02) */ + if (ctime_r(clock, buf) != NULL) + return (buf); + return (NULL); +} + +PHPAPI char *php_asctime_r(const struct tm *tm, char *buf) +{ +/* Modified according to LibC definition : Venkat (30/4/02) */ + if (asctime_r(tm, buf) != NULL) + return (buf); + return (NULL); +} + +PHPAPI struct tm *php_gmtime_r(const time_t *const timep, struct tm *p_tm) +{ +/* Modified according to LibC definition : Venkat (1/5/02) */ + if (gmtime_r(timep, p_tm) != NULL) + return (p_tm); + return (NULL); +} + +#endif /* NETWARE */ #if !defined(HAVE_POSIX_READDIR_R) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /main SAPI.c
hyanantha Thu Oct 24 07:30:27 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/main SAPI.c Log: NetWare related changes/modifications. Index: php4/main/SAPI.c diff -u php4/main/SAPI.c:1.129.2.4 php4/main/SAPI.c:1.129.2.5 --- php4/main/SAPI.c:1.129.2.4 Sun Sep 8 20:32:40 2002 +++ php4/main/SAPI.cThu Oct 24 07:30:26 2002 -18,7 +18,7 +--+ */ -/* $Id: SAPI.c,v 1.129.2.4 2002/09/09 00:32:40 yohgaki Exp $ */ +/* $Id: SAPI.c,v 1.129.2.5 2002/10/24 11:30:26 hyanantha Exp $ */ #include ctype.h #include sys/stat.h -683,10 +683,20 } } +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) +SAPI_API struct stat_libc *sapi_get_stat(TSRMLS_D) +#else SAPI_API struct stat *sapi_get_stat(TSRMLS_D) +#endif { if (sapi_module.get_stat) { +#if (defined(NETWARE) defined(CLIB_STAT_PATCH)) +/* This kind of type-casting is actually wrong; + but doing it for now since global_stat doesn't seem to be used +anywhere particularly */ +return ((struct stat_libc*)sapi_module.get_stat(TSRMLS_C)); +#else return sapi_module.get_stat(TSRMLS_C); +#endif } else { if (!SG(request_info).path_translated || (VCWD_STAT(SG(request_info).path_translated, SG(global_stat))==-1)) { return NULL; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /sapi/apache libpre.c
hyanantha Thu Oct 24 07:33:39 2002 EDT Added files: (Branch: PHP_4_2_0) /php4/sapi/apache libpre.c Log: NetWare related file. Index: php4/sapi/apache/libpre.c +++ php4/sapi/apache/libpre.c -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /sapi/apache php_apache.c
hyanantha Thu Oct 24 07:54:04 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/sapi/apache php_apache.c Log: NetWare related changes/modifications. Index: php4/sapi/apache/php_apache.c diff -u php4/sapi/apache/php_apache.c:1.56 php4/sapi/apache/php_apache.c:1.56.2.1 --- php4/sapi/apache/php_apache.c:1.56 Thu Feb 28 03:27:19 2002 +++ php4/sapi/apache/php_apache.c Thu Oct 24 07:54:03 2002 @@ -17,7 +17,7 @@ | David Sklar [EMAIL PROTECTED] | +--+ */ -/* $Id: php_apache.c,v 1.56 2002/02/28 08:27:19 sebastian Exp $ */ +/* $Id: php_apache.c,v 1.56.2.1 2002/10/24 11:54:03 hyanantha Exp $ */ #define NO_REGEX_EXTRA_H @@ -26,6 +26,14 @@ #include stddef.h #endif +#ifdef NETWARE +#ifdef NEW_LIBC /* Works fine for both Winsock and Berkeley sockets */ +#include netinet/in.h +#else +#include sys/socket.h +#endif +#endif /* NETWARE */ + #include php.h #include ext/standard/head.h #include php_globals.h @@ -51,7 +59,7 @@ php_apache_info_struct php_apache_info; #endif -#ifdef PHP_WIN32 +#if defined(PHP_WIN32) || defined(NETWARE) #include zend.h #include ap_compat.h #else @@ -101,7 +109,7 @@ static PHP_MINIT_FUNCTION(apache) { #ifdef ZTS - ts_allocate_id(php_apache_info_id, sizeof(php_apache_info_struct), php_apache_globals_ctor, NULL); + ts_allocate_id(php_apache_info_id, sizeof(php_apache_info_struct), (void +(*)(void *, void ***))php_apache_globals_ctor, NULL); /* Type-casting done due to +NetWare */ #else php_apache_globals_ctor(php_apache_info TSRMLS_CC); #endif @@ -133,6 +141,9 @@ Terminate apache process after this request */ PHP_FUNCTION(apache_child_terminate) { +#if defined(NETWARE) defined(NETWARE_CLIB_BROKER) + EnterClib(); +#endif #ifndef MULTITHREAD if (AP(terminate_child)) { ap_child_terminate( ((request_rec *)SG(server_context)) ); @@ -142,6 +153,9 @@ #else php_error(E_WARNING, apache_child_terminate() is not supported in this build); #endif +#if defined(NETWARE) defined(NETWARE_CLIB_BROKER) + ExitClib(); +#endif } /* }}} */ @@ -153,6 +167,9 @@ char *note_val; int arg_count = ARG_COUNT(ht); +#if defined(NETWARE) defined(NETWARE_CLIB_BROKER) + EnterClib(); +#endif if (arg_count1 || arg_count2 || zend_get_parameters_ex(arg_count, arg_name, arg_val) ==FAILURE ) { WRONG_PARAM_COUNT; @@ -166,6 +183,9 @@ table_set(((request_rec *)SG(server_context))-notes, (*arg_name)-value.str.val, (*arg_val)-value.str.val); } +#if defined(NETWARE) defined(NETWARE_CLIB_BROKER) + ExitClib(); +#endif if (note_val) { RETURN_STRING(note_val, 1); } else { @@ -180,7 +200,7 @@ { module *modp = NULL; char output_buf[128]; -#if !defined(WIN32) !defined(WINNT) +#if !defined(WIN32) !defined(WINNT) /* This seems to be working for NetWare */ char name[64]; char modulenames[1024]; char *p; @@ -192,6 +212,9 @@ extern gid_t group_id; extern int max_requests_per_child; +#if defined(NETWARE) defined(NETWARE_CLIB_BROKER) + EnterClib(); +#endif serv = ((request_rec *) SG(server_context))-server; @@ -201,6 +224,10 @@ php_info_print_table_row(1, Apache for Windows 95/NT); php_info_print_table_end(); php_info_print_table_start(); +#elif defined(NETWARE) + php_info_print_table_row(1, Apache for NetWare); + php_info_print_table_end(); + php_info_print_table_start(); #else php_info_print_table_row(2, APACHE_INCLUDE, PHP_APACHE_INCLUDE); php_info_print_table_row(2, APACHE_TARGET, PHP_APACHE_TARGET); @@ -216,7 +243,7 @@ php_info_print_table_row(2, Apache API Version, output_buf); sprintf(output_buf, %s:%u, serv-server_hostname, serv-port); php_info_print_table_row(2, Hostname:Port, output_buf); -#if !defined(WIN32) !defined(WINNT) +#if !defined(WIN32) !defined(WINNT) /* This seems to be working for NetWare */ sprintf(output_buf, %s(%d)/%d, user_name, (int)user_id, (int)group_id); php_info_print_table_row(2, User/Group, output_buf); sprintf(output_buf, Per Child: %d - Keep Alive: %s - Max Per Connection: %d, max_requests_per_child, serv-keep_alive ? on:off, serv-keep_alive_max); @@ -224,7 +251,7 @@ #endif sprintf(output_buf, Connection: %d - Keep-Alive: %d, serv-timeout, serv-keep_alive_timeout); php_info_print_table_row(2, Timeouts, output_buf); -#if !defined(WIN32) !defined(WINNT) +#if !defined(WIN32) !defined(WINNT) /* This seems to be working for NetWare */ php_info_print_table_row(2, Server Root, server_root); strcpy(modulenames, ); @@ -238,6 +265,7 @@ strcat(modulenames, , ); }
[PHP-CVS] cvs: php4(PHP_4_2_0) /sapi/apache sapi_apache.c
hyanantha Thu Oct 24 07:54:21 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/sapi/apache sapi_apache.c Log: NetWare related changes/modifications. Index: php4/sapi/apache/sapi_apache.c diff -u php4/sapi/apache/sapi_apache.c:1.39 php4/sapi/apache/sapi_apache.c:1.39.2.1 --- php4/sapi/apache/sapi_apache.c:1.39 Tue Dec 11 10:31:55 2001 +++ php4/sapi/apache/sapi_apache.c Thu Oct 24 07:54:21 2002 @@ -19,13 +19,21 @@ | Stig Bakken [EMAIL PROTECTED]| +--+ */ -/* $Id: sapi_apache.c,v 1.39 2001/12/11 15:31:55 sebastian Exp $ */ +/* $Id: sapi_apache.c,v 1.39.2.1 2002/10/24 11:54:21 hyanantha Exp $ */ #define NO_REGEX_EXTRA_H #ifdef WIN32 #include winsock2.h #include stddef.h #endif + +#ifdef NETWARE +#ifdef NEW_LIBC /* Works fine for both Winsock and Berkeley sockets */ +#include netinet/in.h +#else +#include sys/socket.h +#endif +#endif /* NETWARE */ #include php.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /sapi/apache2filter sapi_apache2.c
hyanantha Thu Oct 24 07:54:59 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/sapi/apache2filtersapi_apache2.c Log: NetWare related changes/modifications. Index: php4/sapi/apache2filter/sapi_apache2.c diff -u php4/sapi/apache2filter/sapi_apache2.c:1.61.2.14 php4/sapi/apache2filter/sapi_apache2.c:1.61.2.15 --- php4/sapi/apache2filter/sapi_apache2.c:1.61.2.14Thu Aug 15 18:27:03 2002 +++ php4/sapi/apache2filter/sapi_apache2.c Thu Oct 24 07:54:58 2002 -43,7 +43,11 #include ap_mpm.h #include php_apache.h - + +#ifdef NETWARE +#undef shutdown /* To avoid Winsock confusion */ +#endif + /* A way to specify the location of the php.ini dir in an apache directive */ char *apache2_php_ini_path_override = NULL; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4(PHP_4_2_0) /sapi/cli php_cli.c
hyanantha Thu Oct 24 07:55:32 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/sapi/cli php_cli.c Log: NetWare related changes/modifications. Index: php4/sapi/cli/php_cli.c diff -u php4/sapi/cli/php_cli.c:1.7.2.5 php4/sapi/cli/php_cli.c:1.7.2.6 --- php4/sapi/cli/php_cli.c:1.7.2.5 Thu Jun 13 04:40:33 2002 +++ php4/sapi/cli/php_cli.c Thu Oct 24 07:55:32 2002 -33,6 +33,18 #include win32/time.h #include win32/signal.h #include process.h +#elif defined(NETWARE) +#ifdef NEW_LIBC +#include sys/timeval.h +#else +#include netware/time_nw.h +#endif +/*#include netware/signal_nw.h*/ +/*#include netware/env.h*//* Temporary */ +/*#include process.h*/ +#ifdef USE_WINSOCK +#include novsock2.h +#endif #else #include build-defs.h #endif -362,6 +374,15 /* startup after we get the above ini override se we get things right */ if (php_module_startup(cli_sapi_module)==FAILURE) { +#ifdef NETWARE + /* Without the below two functions, it will leak memory!! + Don't know why they were not there in the first place. + */ + sapi_shutdown(); +#ifdef ZTS + tsrm_shutdown(); +#endif +#endif return FAILURE; } -643,6 +664,13 } zend_end_try(); php_module_shutdown(TSRMLS_C); + +#ifdef NETWARE + /* Without the below function, it will leak memory!! + Don't know why it was not there in the first place. + */ + sapi_shutdown(); +#endif #ifdef ZTS tsrm_shutdown(); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard image.c
Oh ok. Sorry if this caused any inconvenience, but I saw your mail only now! Well, I thought I should do it individually since I also had some new files to be added for NetWare under a few different folders. I had to cvs add ... and then cvs commit ... for these new files. If I had done a cvs commit on the php4 folder, would it have taken care of adding and then committing the new files also under different folders? I know it takes care of the existing files that have changed. I am now left with files under TSRM and ZEND folders to check-in. There are a couple of new files for NetWare there also. But I am waiting for write access for me to these areas. Thanks, Ananth. Derick Rethans [EMAIL PROTECTED] 10/24/02 05:25AM On Thu, 24 Oct 2002, Anantha Kesari H Y wrote: hyanantha Thu Oct 24 07:16:57 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/ext/standardimage.c Log: NetWare related changes/modifications. You can also commit all files in one run ... please :) Derick Index: php4/ext/standard/image.c diff -u php4/ext/standard/image.c:1.44.2.2 php4/ext/standard/image.c:1.44.2.3 --- php4/ext/standard/image.c:1.44.2.2Tue Mar 12 00:57:28 2002 +++ php4/ext/standard/image.c Thu Oct 24 07:16:57 2002 @@ -16,7 +16,7 @@ | Marcus Boerger [EMAIL PROTECTED] | +--+ */ -/* $Id: image.c,v 1.44.2.2 2002/03/12 05:57:28 helly Exp $ */ +/* $Id: image.c,v 1.44.2.3 2002/10/24 11:16:57 hyanantha Exp $ */ /* * Based on Daniel Schmitt's imageinfo.c which carried the following * Copyright notice. @@ -39,6 +39,11 @@ #include php.h #include stdio.h + +#if defined(NETWARE) !defined(NEW_LIBC) +#include sys/socket.h +#endif + #if HAVE_FCNTL_H #include fcntl.h #endif @@ -82,10 +87,10 @@ FP_FREAD(temp, 3, socketd, fp, issock); /* fseek(fp, 6L, SEEK_SET); */ - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char*)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ /* Type-casting done due to NetWare */ result-width = (unsigned short)a[0] | (((unsigned short)a[1])8); - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char *)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ /* Type-casting done due to NetWare */ result-height = (unsigned short)a[0] | (((unsigned short)a[1])8); return result; @@ -104,7 +109,7 @@ result = (struct gfxinfo *) ecalloc(1, sizeof(struct gfxinfo)); FP_FREAD(temp, sizeof(temp), socketd, fp, issock); - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) { + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) {/* Type-casting done due to NetWare */ in_height = 0; in_width = 0; } else { @@ -169,7 +174,7 @@ result = (struct gfxinfo *) ecalloc (1, sizeof (struct gfxinfo)); FP_FREAD(temp, 5, socketd, fp, issock); /* fseek(fp, 8L, SEEK_SET); */ - FP_FREAD(a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ + FP_FREAD((char *)a, sizeof(a), socketd, fp, issock); /* fread(a, sizeof(a), 1, fp); */ /* Type-casting done due to NetWare */ bits = php_swf_get_bits (a, 0, 5); result-width = (php_swf_get_bits (a, 5 + bits, bits) - php_swf_get_bits (a, 5, bits)) / 20; @@ -192,7 +197,7 @@ FP_FREAD(temp, sizeof(temp), socketd, fp, issock); /* fseek(fp, 16L, SEEK_SET); */ - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) { + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) {/* Type-casting done due to NetWare */ in_width = 0; in_height = 0; } else { @@ -249,8 +254,7 @@ unsigned char a[2]; /* just return 0 if we hit the end-of-file */ - if((FP_FREAD(a, sizeof(a), socketd, fp, issock)) = 0) return 0; - + if((FP_FREAD((char *)a, sizeof(a), socketd, fp, issock)) = 0) return 0; /* Type-casting done due to NetWare */ return (((unsigned short) a[ 0 ]) 8) + ((unsigned short) a[ 1 ]); } /* }}} */ @@ -316,16 +320,16 @@ buffer = emalloc(length); if ( !buffer) return; - if (FP_FREAD(buffer, (long) length, socketd, fp, issock) = 0) { + if (FP_FREAD((char *)buffer, (long) length, socketd, fp, issock) = 0) { /* Type-casting done due to NetWare */ efree(buffer); return; } - sprintf(markername, APP%d, marker - M_APP0); + sprintf((char *)markername, APP%d, marker - M_APP0); /* Type-casting done due to NetWare */ - if (zend_hash_find(Z_ARRVAL_P(info), markername, strlen(markername)+1, (void **) tmp) == FAILURE) { + if
[PHP-CVS] cvs: php4(PHP_4_2_0) /win32 sendmail.c sendmail.h
hyanantha Thu Oct 24 08:08:54 2002 EDT Modified files: (Branch: PHP_4_2_0) /php4/win32 sendmail.c sendmail.h Log: NetWare related changes/modifications. Index: php4/win32/sendmail.c diff -u php4/win32/sendmail.c:1.24.2.1 php4/win32/sendmail.c:1.24.2.2 --- php4/win32/sendmail.c:1.24.2.1 Tue May 14 10:17:04 2002 +++ php4/win32/sendmail.c Thu Oct 24 08:08:54 2002 -1,6 +1,6 /* - *PHP Sendmail for Windows. + *PHP Sendmail for Windows and NetWare. * * This file is rewriten specificly for PHPFI. Some functionality * has been removed (MIME and file attachments). This code was -18,17 +18,31 * */ -/* $Id: sendmail.c,v 1.24.2.1 2002/05/14 14:17:04 mfischer Exp $ */ +/* $Id: sendmail.c,v 1.24.2.2 2002/10/24 12:08:54 hyanantha Exp $ */ #include php.h /*php specific */ #include stdio.h #include stdlib.h +#ifndef NETWARE #include winsock.h +#else /* NETWARE */ +#ifdef USE_WINSOCK +/*#include ws2nlm.h*/ +#include novsock2.h +#else +#include sys/socket.h/* For struct sockaddr, 'PF_INET' and 'AF_INET' */ +#include netinet\in.h/* For struct sockaddr_in */ +#include netdb.h /* For struct hostent */ +/*#include ws2name.h*/ +#endif /* USE_WINSOCK */ +#endif /* NETWARE */ #include time.h #include string.h +#ifndef NETWARE #include malloc.h #include memory.h #include winbase.h +#endif /* NETWARE */ #include sendmail.h #include php_ini.h -51,18 +65,34 char Buffer[MAIL_BUFFER_SIZE]; /* socket related data */ +#ifdef NETWARE +typedef int SOCKET;/* Borrowed from winsock\novsock2.h */ +typedef struct sockaddr_in SOCKADDR_IN; +typedef struct sockaddr * LPSOCKADDR; +typedef struct hostent * LPHOSTENT; + +#define INVALID_SOCKET (SOCKET)(~0) /* Borrowed from winsock\novsock2.h */ +#endif /* NETWARE */ SOCKET sc; +#ifndef NETWARE WSADATA Data; struct hostent *adr; +#endif /* NETWARE */ SOCKADDR_IN sock_in; +#ifndef NETWARE int WinsockStarted; /* values set by the constructor */ char *AppName; +#endif /* NETWARE */ char MailHost[HOST_NAME_LEN]; char LocalHost[HOST_NAME_LEN]; #endif char seps[] = ,\t\n; +#ifndef NETWARE char *php_mailer = PHP 4.0 WIN32; +#else +char *php_mailer = PHP 4.0 NetWare; +#endif /* NETWARE */ char *get_header(char *h, char *headers); -88,7 +118,8 {Bad Message Return Path}, {Bad Mail Host}, {Bad Message File}, - {\sendmail_from\ NOT set in php.ini}, + {\sendmail_from\ NOT set in php.ini}, + {Mailserver rejected our \sendmail_from\ setting} /* 20 */ }; -113,7 +144,9 int ret; char *RPath = NULL; +#ifndef NETWARE WinsockStarted = FALSE; +#endif if (host == NULL) { *error = BAD_MAIL_HOST; -127,8 +160,10 if (INI_STR(sendmail_from)){ RPath = estrdup(INI_STR(sendmail_from)); - } else { - *error = W32_SM_SENDMAIL_FROM_NOT_SET; + } else { + + *error = W32_SM_SENDMAIL_FROM_NOT_SET; + return FAILURE; } -166,7 +201,14 */ shutdown(sc, 0); +#ifndef NETWARE closesocket(sc); +#else + /* closesocket commented out since it was giving undefined symbol linker +error + close added in its place + */ + close(sc); +#endif /* NETWARE */ } -180,11 +222,14 //***/ char *GetSMErrorText(int index) { - + + if (MIN_ERROR_INDEX = index index MAX_ERROR_INDEX) { - return (ErrorMessages[index]); + return (ErrorMessages[index]); + } else { - return (ErrorMessages[UNKNOWN_ERROR]); + return (ErrorMessages[UNKNOWN_ERROR]); + } } -258,10 +303,13 /* Send mail to all Cc rcpt's */ efree(tempMailTo); if (headers (pos1 = strstr(headers, Cc:))) { - if (NULL == (pos2 = strstr(pos1, \r\n))) { - tempMailTo = estrndup(pos1, strlen(pos1)); + if (NULL == (pos2 = strstr(pos1, \r\n))) { + + tempMailTo = estrndup(pos1, strlen(pos1)); + } else { - tempMailTo = estrndup(pos1, pos2-pos1); + tempMailTo = estrndup(pos1, pos2-pos1); + } token = strtok(tempMailTo, ,); -454,7 +502,11 // Author/Date: jcar 20/9/96 // History: /// +#ifndef NETWARE int Post(LPCSTR msg) +#else +int Post(char * msg) +#endif /* NETWARE */ { int len = strlen(msg); int slen; -529,7 +581,11 // Author/Date: jcar 20/9/96 // History: /// +#ifndef NETWARE unsigned long GetAddr(LPSTR szHost) +#else +unsigned long
Re: [PHP-CVS] cvs: php4(PHP_4_2_0) /ext/standard image.c
On Thu, 24 Oct 2002, Ananth Kesari wrote: Oh ok. Sorry if this caused any inconvenience, but I saw your mail only now! Well, I thought I should do it individually since I also had some new files to be added for NetWare under a few different folders. I had to cvs add ... and then cvs commit ... for these new files. If I had done a cvs commit on the php4 folder, would it have taken care of adding and then committing the new files also under different folders? I know it takes care of the existing files that have changed. yeah, that works just fine, but you only need to add them by hand. A couple of cvs add's in different folders can be committed with one cvs commit in the root dir. I am now left with files under TSRM and ZEND folders to check-in. There are a couple of new files for NetWare there also. But I am waiting for write access for me to these areas. You can write to group, or provide a patch so that somebody else can committ it for you. regards, Derick -- --- Derick Rethans http://derickrethans.nl/ JDI Media Solutions --[ if you hold a unix shell to your ear, do you hear the c? ]- -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 / acinclude.m4 configure.in /ext/standard config.m4 math.c
sas Thu Oct 24 08:21:07 2002 EDT Modified files: /php4 acinclude.m4 configure.in /php4/ext/standard config.m4 math.c Log: Make PHP compile out-of-the-box with uClibc Index: php4/acinclude.m4 diff -u php4/acinclude.m4:1.215 php4/acinclude.m4:1.216 --- php4/acinclude.m4:1.215 Thu Oct 24 06:41:36 2002 +++ php4/acinclude.m4 Thu Oct 24 08:21:06 2002 -1,4 +1,4 -dnl $Id: acinclude.m4,v 1.215 2002/10/24 10:41:36 sas Exp $ +dnl $Id: acinclude.m4,v 1.216 2002/10/24 12:21:06 sas Exp $ dnl dnl This file contains local autoconf functions. -1679,6 +1679,13 AC_CHECK_LIB($2, $1, [found=yes], [ AC_CHECK_LIB($2, __$1, [found=yes], [found=no]) ]) + + if test $found = yes; then +ac_libs=$LIBS +LIBS=$LIBS -l$2 +AC_TRY_RUN([main() { return (0); }],[found=yes],[found=no],[found=no]) +LIBS=$ac_libs + fi if test $found = yes; then PHP_ADD_LIBRARY($2) Index: php4/configure.in diff -u php4/configure.in:1.386 php4/configure.in:1.387 --- php4/configure.in:1.386 Tue Oct 22 20:21:43 2002 +++ php4/configure.in Thu Oct 24 08:21:06 2002 -1,4 +1,4 -dnl ## $Id: configure.in,v 1.386 2002/10/23 00:21:43 sniper Exp $ -*- sh -*- +dnl ## $Id: configure.in,v 1.387 2002/10/24 12:21:06 sas Exp $ -*- sh -*- dnl ## Process this file with autoconf to produce a configure script. divert(1) -279,7 +279,7 PHP_CHECK_FUNC(gethostbyaddr, nsl) PHP_CHECK_FUNC(yp_get_default_domain, nsl) -AC_CHECK_LIB(dl, dlopen, [PHP_ADD_LIBRARY(dl)]) +PHP_CHECK_FUNC(dlopen, dl) AC_CHECK_LIB(m, sin) dnl Check for resolver routines. -802,6 +802,7 PHP_CONFIGURE_PART(Configuring Zend) LIBZEND_BASIC_CHECKS +LIBZEND_DLSYM_CHECK LIBZEND_OTHER_CHECKS TSRM_LIB='TSRM/libtsrm.la' Index: php4/ext/standard/config.m4 diff -u php4/ext/standard/config.m4:1.44 php4/ext/standard/config.m4:1.45 --- php4/ext/standard/config.m4:1.44Mon Oct 21 19:41:38 2002 +++ php4/ext/standard/config.m4 Thu Oct 24 08:21:06 2002 -1,4 +1,4 -dnl $Id: config.m4,v 1.44 2002/10/21 23:41:38 sniper Exp $ -*- sh -*- +dnl $Id: config.m4,v 1.45 2002/10/24 12:21:06 sas Exp $ -*- sh -*- divert(3)dnl -189,7 +189,7 dnl EXTRA_LIBS=$EXTRA_LIBS -lpam dnl AC_DEFINE(HAVE_LIBPAM,1,[ ]) ], []) -AC_CHECK_FUNCS(getcwd getwd) +AC_CHECK_FUNCS(getcwd getwd asinh acosh atanh log1p hypot) AC_CRYPT_CAP AC_FLUSH_IO Index: php4/ext/standard/math.c diff -u php4/ext/standard/math.c:1.90 php4/ext/standard/math.c:1.91 --- php4/ext/standard/math.c:1.90 Tue Oct 15 10:51:01 2002 +++ php4/ext/standard/math.cThu Oct 24 08:21:07 2002 -19,7 +19,7 +--+ */ -/* $Id: math.c,v 1.90 2002/10/15 14:51:01 sterling Exp $ */ +/* $Id: math.c,v 1.91 2002/10/24 12:21:07 sas Exp $ */ #include php.h #include php_math.h -321,6 +321,7 PHP_FUNCTION(asinh) { +#ifdef HAVE_ASINH zval **num; if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, num) == FAILURE) { -329,6 +330,7 convert_to_double_ex(num); Z_DVAL_P(return_value) = asinh(Z_DVAL_PP(num)); Z_TYPE_P(return_value) = IS_DOUBLE; +#endif } /* }}} */ -337,6 +339,7 PHP_FUNCTION(acosh) { +#ifdef HAVE_ACOSH zval **num; if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, num) == FAILURE) { -345,6 +348,7 convert_to_double_ex(num); Z_DVAL_P(return_value) = acosh(Z_DVAL_PP(num)); Z_TYPE_P(return_value) = IS_DOUBLE; +#endif } /* }}} */ -353,6 +357,7 PHP_FUNCTION(atanh) { +#ifdef HAVE_ATANH zval **num; if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, num) == FAILURE) { -361,6 +366,7 convert_to_double_ex(num); Z_DVAL_P(return_value) = atanh(Z_DVAL_PP(num)); Z_TYPE_P(return_value) = IS_DOUBLE; +#endif } /* }}} */ -504,6 +510,7 PHP_FUNCTION(log1p) { +#ifdef HAVE_LOG1P zval **num; if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, num) == FAILURE) { -512,6 +519,7 convert_to_double_ex(num); Z_DVAL_P(return_value) = log1p(Z_DVAL_PP(num)); Z_TYPE_P(return_value) = IS_DOUBLE; +#endif } /* }}} */ -577,6 +585,7 PHP_FUNCTION(hypot) { +#ifdef HAVE_HYPOT zval **num1, **num2; if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, num1, num2) == FAILURE) { -586,6 +595,7 convert_to_double_ex(num2); Z_DVAL_P(return_value) = hypot(Z_DVAL_PP(num1), Z_DVAL_PP(num2)); Z_TYPE_P(return_value) = IS_DOUBLE; +#endif } /* }}} */ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] cvs: php4 / acinclude.m4 configure.in /ext/standardconfig.m4 math.c
On Thu, 24 Oct 2002, Sascha Schumann wrote: sas Thu Oct 24 08:21:07 2002 EDT Modified files: /php4 acinclude.m4 configure.in /php4/ext/standardconfig.m4 math.c Log: Make PHP compile out-of-the-box with uClibc PHP_FUNCTION(asinh) { +#ifdef HAVE_ASINH zval **num; if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, num) == FAILURE) { -329,6 +330,7 convert_to_double_ex(num); Z_DVAL_P(return_value) = asinh(Z_DVAL_PP(num)); Z_TYPE_P(return_value) = IS_DOUBLE; +#endif } I thought the general consesus was to not define a function at all if it is not implemented. Better make function_exists() work on them so that you can code workarounds in your code... Derick -- --- Derick Rethans http://derickrethans.nl/ JDI Media Solutions --[ if you hold a unix shell to your ear, do you hear the c? ]- -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/dbx dbx_oci8.c
derick Thu Oct 24 08:52:13 2002 EDT Modified files: /php4/ext/dbx dbx_oci8.c Log: - True and false are not always defined, used numbers now Index: php4/ext/dbx/dbx_oci8.c diff -u php4/ext/dbx/dbx_oci8.c:1.6 php4/ext/dbx/dbx_oci8.c:1.7 --- php4/ext/dbx/dbx_oci8.c:1.6 Wed Oct 23 06:50:22 2002 +++ php4/ext/dbx/dbx_oci8.c Thu Oct 24 08:52:13 2002 -20,7 +20,7 +--+ */ -/* $Id: dbx_oci8.c,v 1.6 2002/10/23 10:50:22 mboeren Exp $ */ +/* $Id: dbx_oci8.c,v 1.7 2002/10/24 12:52:13 derick Exp $ */ #include dbx.h #include dbx_oci8.h -108,7 +108,7 arguments[0]=returned_zval; dbx_call_any_function(INTERNAL_FUNCTION_PARAM_PASSTHRU, OCIExecute, execute_zval, number_of_arguments, arguments); /* OCIExecute returns a bool for success or failure */ - if (!execute_zval || Z_TYPE_P(execute_zval)!=IS_BOOL || Z_BVAL_P(execute_zval)==FALSE) { + if (!execute_zval || Z_TYPE_P(execute_zval)!=IS_BOOL || +Z_BVAL_P(execute_zval)==0) { if (execute_zval) zval_ptr_dtor(execute_zval); zval_ptr_dtor(returned_zval); return 0; -131,7 +131,7 /* it is not a select, so just return success */ zval_ptr_dtor(returned_zval); MAKE_STD_ZVAL(returned_zval); - ZVAL_BOOL(returned_zval, TRUE); + ZVAL_BOOL(returned_zval, 1); MOVE_RETURNED_TO_RV(rv, returned_zval); } if (statementtype_zval) zval_ptr_dtor(statementtype_zval); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 / configure.in /ext/dbase dbase.c /ext/dotnet php_dotnet.h /ext/fbsql php_fbsql.c /ext/filepro filepro.c /ext/gd gdcache.c /ext/hwapi hwapi.cpp /ext/hyperwave hw.c /ext/imap php_imap.h /ext/informix ifx.ec /ext/mcal php_mcal.h /ext/mysql php_mysql.c /ext/oci8 oci8.c /ext/odbc php_odbc.c /ext/oracle oracle.c /ext/standard dl.c fsock.c info.c mail.c /ext/xml xml.c /main main.c php.h php_ini.c streams.c /regex regex_extra.h /sapi/apache php_apache.c /sapi/cgi cgi_main.c /sapi/cli php_cli.c /sapi/servlet servlet.c
sas Thu Oct 24 09:14:51 2002 EDT Modified files: /php4 configure.in /php4/ext/dbase dbase.c /php4/ext/dotnetphp_dotnet.h /php4/ext/fbsql php_fbsql.c /php4/ext/filepro filepro.c /php4/ext/gdgdcache.c /php4/ext/hwapi hwapi.cpp /php4/ext/hyperwave hw.c /php4/ext/imap php_imap.h /php4/ext/informix ifx.ec /php4/ext/mcal php_mcal.h /php4/ext/mysql php_mysql.c /php4/ext/oci8 oci8.c /php4/ext/odbc php_odbc.c /php4/ext/oracleoracle.c /php4/ext/standard dl.c fsock.c info.c mail.c /php4/ext/xml xml.c /php4/main main.c php.h php_ini.c streams.c /php4/regex regex_extra.h /php4/sapi/apache php_apache.c /php4/sapi/cgi cgi_main.c /php4/sapi/cli php_cli.c /php4/sapi/servlet servlet.c Log: centralize #include build-defs.h and drop (sometimes inconsistent) other instances Index: php4/configure.in diff -u php4/configure.in:1.387 php4/configure.in:1.388 --- php4/configure.in:1.387 Thu Oct 24 08:21:06 2002 +++ php4/configure.in Thu Oct 24 09:14:32 2002 @@ -1,4 +1,4 @@ -dnl ## $Id: configure.in,v 1.387 2002/10/24 12:21:06 sas Exp $ -*- sh -*- +dnl ## $Id: configure.in,v 1.388 2002/10/24 13:14:32 sas Exp $ -*- sh -*- dnl ## Process this file with autoconf to produce a configure script. divert(1) @@ -325,6 +325,7 @@ locale.h \ monetary.h \ mach-o/dyld.h \ +netdb.h \ pwd.h \ resolv.h \ signal.h \ @@ -1107,6 +1108,8 @@ PHP_GEN_BUILD_DIRS PHP_GEN_GLOBAL_MAKEFILE + +AC_DEFINE([HAVE_BUILD_DEFS_H], 1, [ ]) $php_shtool mkdir -p pear/scripts ALL_OUTPUT_FILES=php4.spec main/build-defs.h \ Index: php4/ext/dbase/dbase.c diff -u php4/ext/dbase/dbase.c:1.59 php4/ext/dbase/dbase.c:1.60 --- php4/ext/dbase/dbase.c:1.59 Sun Jun 16 22:27:34 2002 +++ php4/ext/dbase/dbase.c Thu Oct 24 09:14:33 2002 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: dbase.c,v 1.59 2002/06/17 02:27:34 sniper Exp $ */ +/* $Id: dbase.c,v 1.60 2002/10/24 13:14:33 sas Exp $ */ #ifdef HAVE_CONFIG_H #include config.h @@ -760,7 +760,7 @@ #ifdef COMPILE_DL_DBASE ZEND_GET_MODULE(dbase) -#if (WIN32|WINNT) defined(THREAD_SAFE) +#if defined(PHP_WIN32) defined(THREAD_SAFE) /*NOTE: You should have an odbc.def file where you export DllMain*/ Index: php4/ext/dotnet/php_dotnet.h diff -u php4/ext/dotnet/php_dotnet.h:1.2 php4/ext/dotnet/php_dotnet.h:1.3 --- php4/ext/dotnet/php_dotnet.h:1.2Sun Jul 29 21:56:24 2001 +++ php4/ext/dotnet/php_dotnet.hThu Oct 24 09:14:33 2002 @@ -1,7 +1,7 @@ #ifndef PHP_DOTNET_H #define PHP_DOTNET_H -#if WIN32|WINNT +#ifdef PHP_WIN32 PHP_MINIT_FUNCTION(DOTNET); PHP_MSHUTDOWN_FUNCTION(DOTNET); @@ -14,7 +14,7 @@ #define DOTNET_module_ptr NULL -#endif /* Win32|WINNT */ +#endif /* PHP_WIN32 */ #define phpext_DOTNET_ptr DOTNET_module_ptr Index: php4/ext/fbsql/php_fbsql.c diff -u php4/ext/fbsql/php_fbsql.c:1.85 php4/ext/fbsql/php_fbsql.c:1.86 --- php4/ext/fbsql/php_fbsql.c:1.85 Sat Oct 5 22:10:19 2002 +++ php4/ext/fbsql/php_fbsql.c Thu Oct 24 09:14:34 2002 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: php_fbsql.c,v 1.85 2002/10/06 02:10:19 fmk Exp $ */ +/* $Id: php_fbsql.c,v 1.86 2002/10/24 13:14:34 sas Exp $ */ /* TODO: * @@ -42,11 +42,10 @@ #include ext/standard/info.h #include ext/standard/php_string.h -#if WIN32|WINNT +#ifdef PHP_WIN32 #include winsock.h #else #include php_config.h -#include build-defs.h #if HAVE_SYS_TYPES_H #include sys/types.h Index: php4/ext/filepro/filepro.c diff -u php4/ext/filepro/filepro.c:1.46 php4/ext/filepro/filepro.c:1.47 --- php4/ext/filepro/filepro.c:1.46 Thu Jun 27 02:54:51 2002 +++ php4/ext/filepro/filepro.c Thu Oct 24 09:14:35 2002 @@ -16,7 +16,7 @@ +--+ */ -/* $Id: filepro.c,v 1.46 2002/06/27 06:54:51 derick Exp $ */ +/* $Id: filepro.c,v 1.47 2002/10/24 13:14:35 sas Exp $ */ /* filePro 4.x support developed by Chad Robinson, [EMAIL PROTECTED] @@ -151,7 +151,7 @@ #ifdef COMPILE_DL_FILEPRO ZEND_GET_MODULE(filepro) -#if (WIN32|WINNT) defined(THREAD_SAFE) +#if defined(PHP_WIN32) defined(THREAD_SAFE) /*NOTE: You should have an odbc.def file where you export DllMain*/ Index: php4/ext/gd/gdcache.c diff -u php4/ext/gd/gdcache.c:1.4 php4/ext/gd/gdcache.c:1.5 --- php4/ext/gd/gdcache.c:1.4 Thu Aug 19 02:32:07 1999 +++ php4/ext/gd/gdcache.c Thu Oct 24 09:14:35 2002 @@ -1,5 +1,5 @@ /* - * $Id: gdcache.c,v 1.4 1999/08/19 06:32:07 rasmus Exp $ + * $Id: gdcache.c,v 1.5 2002/10/24 13:14:35 sas Exp $ * * Caches of pointers to user structs in which the least-recently-used * element is replaced in the event of a cache miss after the cache has @@ -37,7 +37,7 @@ */ /* This just
[PHP-CVS] cvs: php4 /sapi/cli php_cli.c
derick Thu Oct 24 10:01:40 2002 EDT Modified files: /php4/sapi/cli php_cli.c Log: - whitespace Index: php4/sapi/cli/php_cli.c diff -u php4/sapi/cli/php_cli.c:1.41 php4/sapi/cli/php_cli.c:1.42 --- php4/sapi/cli/php_cli.c:1.41Thu Oct 24 09:25:57 2002 +++ php4/sapi/cli/php_cli.c Thu Oct 24 10:01:39 2002 -109,7 +109,9 long ret; ret = write(STDOUT_FILENO, str, str_length); - if (ret = 0) return 0; + if (ret = 0) { + return 0; + } return ret; #else size_t ret; -748,8 +750,9 } zend_end_try(); out: - if (module_started) + if (module_started) { php_module_shutdown(TSRMLS_C); + } sapi_shutdown(); #ifdef ZTS tsrm_shutdown(); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/standard dl.c
moriyoshi Thu Oct 24 10:01:46 2002 EDT Modified files: /php4/ext/standard dl.c Log: Fix build Index: php4/ext/standard/dl.c diff -u php4/ext/standard/dl.c:1.76 php4/ext/standard/dl.c:1.77 --- php4/ext/standard/dl.c:1.76 Thu Oct 24 09:14:42 2002 +++ php4/ext/standard/dl.c Thu Oct 24 10:01:45 2002 -18,13 +18,14 +--+ */ -/* $Id: dl.c,v 1.76 2002/10/24 13:14:42 sas Exp $ */ +/* $Id: dl.c,v 1.77 2002/10/24 14:01:45 moriyoshi Exp $ */ #include php.h #include dl.h #include php_globals.h #include ext/standard/info.h #include SAPI.h +#include build-defs.h #if defined(HAVE_LIBDL) || HAVE_MACH_O_DYLD_H #include stdlib.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/standard dl.c
moriyoshi Thu Oct 24 10:12:06 2002 EDT Modified files: /php4/ext/standard dl.c Log: Reverted because my patch doesn't make sense: it was just my problem. Index: php4/ext/standard/dl.c diff -u php4/ext/standard/dl.c:1.77 php4/ext/standard/dl.c:1.78 --- php4/ext/standard/dl.c:1.77 Thu Oct 24 10:01:45 2002 +++ php4/ext/standard/dl.c Thu Oct 24 10:12:06 2002 -18,14 +18,13 +--+ */ -/* $Id: dl.c,v 1.77 2002/10/24 14:01:45 moriyoshi Exp $ */ +/* $Id: dl.c,v 1.78 2002/10/24 14:12:06 moriyoshi Exp $ */ #include php.h #include dl.h #include php_globals.h #include ext/standard/info.h #include SAPI.h -#include build-defs.h #if defined(HAVE_LIBDL) || HAVE_MACH_O_DYLD_H #include stdlib.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/dbx dbx_oci8.c
mboeren Thu Oct 24 10:26:14 2002 EDT Modified files: /php4/ext/dbx dbx_oci8.c Log: Changed the dbx_oci8 behaviour to return lowercase column-names, which is a hack but at least it makes it easier for users to create portable apps. # Perhaps this should be controlled by a (.ini?) directive or define # which determines the change (toupper, tolower, nochange)? Index: php4/ext/dbx/dbx_oci8.c diff -u php4/ext/dbx/dbx_oci8.c:1.7 php4/ext/dbx/dbx_oci8.c:1.8 --- php4/ext/dbx/dbx_oci8.c:1.7 Thu Oct 24 08:52:13 2002 +++ php4/ext/dbx/dbx_oci8.c Thu Oct 24 10:26:14 2002 -20,10 +20,11 +--+ */ -/* $Id: dbx_oci8.c,v 1.7 2002/10/24 12:52:13 derick Exp $ */ +/* $Id: dbx_oci8.c,v 1.8 2002/10/24 14:26:14 mboeren Exp $ */ #include dbx.h #include dbx_oci8.h +#include ext/standard/php_string.h /* for auto-change column names to lowercase*/ #define OCI_ASSOC10 #define OCI_NUM 11 -178,6 +179,7 return 0; } FREE_ZVAL(zval_column_index); + php_strtolower(Z_STRVAL_P(returned_zval), Z_STRLEN_P(returned_zval)); MOVE_RETURNED_TO_RV(rv, returned_zval); return 1; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/standard html.c
moriyoshi Thu Oct 24 17:10:45 2002 EDT Modified files: /php4/ext/standard html.c Log: Fixed ISO-8859-1 handling. Index: php4/ext/standard/html.c diff -u php4/ext/standard/html.c:1.57 php4/ext/standard/html.c:1.58 --- php4/ext/standard/html.c:1.57 Thu Oct 24 15:52:30 2002 +++ php4/ext/standard/html.cThu Oct 24 17:10:45 2002 -18,7 +18,7 +--+ */ -/* $Id: html.c,v 1.57 2002/10/24 19:52:30 moriyoshi Exp $ */ +/* $Id: html.c,v 1.58 2002/10/24 21:10:45 moriyoshi Exp $ */ #include php.h #include reg.h -533,6 +533,9 #if HAVE_MBSTRING /* XXX: Ugly things. Why don't we look for a more sophisticated way? */ switch (MBSTRG(internal_encoding)) { + case mbfl_no_encoding_8859_1: + return cs_8859_1; + case mbfl_no_encoding_utf8: return cs_utf_8; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/standard/tests/strings htmlentities1.phpt htmlentities2.phpt htmlentities3.phpt htmlentities4.phpt htmlentities5.phpt htmlentities6.phpt htmlentities7.phpt htmlentities8.phpt htmlentities9.phpt
moriyoshi Thu Oct 24 17:11:41 2002 EDT Added files: /php4/ext/standard/tests/stringshtmlentities1.phpt htmlentities2.phpt htmlentities3.phpt htmlentities4.phpt htmlentities5.phpt htmlentities6.phpt htmlentities7.phpt htmlentities8.phpt htmlentities9.phpt Log: Added new test cases for htmlentities Index: php4/ext/standard/tests/strings/htmlentities1.phpt +++ php4/ext/standard/tests/strings/htmlentities1.phpt --TEST-- htmlentities() test 1 (cp1252) --INI-- mbstring.internal_encoding=pass --FILE-- ?php var_dump(htmlentities(\x82\x86\x99\x9f, ENT_QUOTES, 'cp1252')); var_dump(htmlentities(\x80\xa2\xa3\xa4\xa5, ENT_QUOTES, 'cp1252')); ? --EXPECT-- string(28) sbquo;dagger;trade;Yuml; string(32) euro;cent;pound;curren;yen; Index: php4/ext/standard/tests/strings/htmlentities2.phpt +++ php4/ext/standard/tests/strings/htmlentities2.phpt --TEST-- htmlentities() test 2 (setlocale / fr_FR.ISO-8859-15) --SKIPIF-- ?php setlocale( LC_CTYPE, fr_FR.ISO-8859-15 ) or die( skip\n ); ? --INI-- mbstring.internal_encoding=pass --FILE-- ?php setlocale( LC_CTYPE, fr_FR.ISO-8859-15 ); var_dump(htmlentities(\xbc\xbd\xbe, ENT_QUOTES, '')); ? --EXPECT-- string(20) OElig;oelig;Yuml; Index: php4/ext/standard/tests/strings/htmlentities3.phpt +++ php4/ext/standard/tests/strings/htmlentities3.phpt --TEST-- htmlentities() test 3 (setlocale / de_DE.ISO-8859-1) --SKIPIF-- ?php setlocale( LC_CTYPE, de_DE.ISO-8859-1 ) or die(skip\n); ? --INI-- mbstring.internal_encoding=pass --FILE-- ?php setlocale( LC_CTYPE, de_DE.ISO-8859-1 ); var_dump(htmlentities(\xe4\xf6\xfc, ENT_QUOTES, '')); ? --EXPECT-- string(18) auml;ouml;uuml; Index: php4/ext/standard/tests/strings/htmlentities4.phpt +++ php4/ext/standard/tests/strings/htmlentities4.phpt --TEST-- htmlentities() test 4 (setlocale / ja_JP.EUC-JP) --SKIPIF-- ?php setlocale( LC_CTYPE, ja_JP.EUC-JP ) or die(skip\n); ? --INI-- mbstring.internal_encoding=pass --FILE-- ?php setlocale( LC_CTYPE, ja_JP.EUC-JP ); var_dump(htmlentities(\xa1\xa2\xa1\xa3\xa1\xa4, ENT_QUOTES, '')); ? --EXPECT-- string(6) ¡¢¡£¡¤ Index: php4/ext/standard/tests/strings/htmlentities5.phpt +++ php4/ext/standard/tests/strings/htmlentities5.phpt --TEST-- htmlentities() test 5 (mbstring / cp1252) --INI-- output_handler= mbstring.internal_encoding=cp1252 --SKIPIF-- ?php function_exists('mb_internal_encoding') or die(skip\n); ? --FILE-- ?php print mb_internal_encoding().\n; var_dump(htmlentities(\x82\x86\x99\x9f, ENT_QUOTES, '')); var_dump(htmlentities(\x80\xa2\xa3\xa4\xa5, ENT_QUOTES, '')); ? --EXPECT-- Windows-1252 string(28) sbquo;dagger;trade;Yuml; string(32) euro;cent;pound;curren;yen; Index: php4/ext/standard/tests/strings/htmlentities6.phpt +++ php4/ext/standard/tests/strings/htmlentities6.phpt --TEST-- htmlentities() test 6 (mbstring / ISO-8859-15) --INI-- output_handler= mbstring.internal_encoding=ISO-8859-15 --SKIPIF-- ?php function_exists('mb_internal_encoding') or die(skip\n); ? --FILE-- ?php print mb_internal_encoding().\n; var_dump(htmlentities(\xbc\xbd\xbe, ENT_QUOTES, '')); ? --EXPECT-- ISO-8859-15 string(20) OElig;oelig;Yuml; Index: php4/ext/standard/tests/strings/htmlentities7.phpt +++ php4/ext/standard/tests/strings/htmlentities7.phpt --TEST-- htmlentities() test 7 (mbstring / ISO-8859-1) --INI-- output_handler= mbstring.internal_encoding=ISO-8859-1 --SKIPIF-- ?php function_exists('mb_internal_encoding') or die(skip\n); ? --FILE-- ?php print mb_internal_encoding().\n; var_dump(htmlentities(\xe4\xf6\xfc, ENT_QUOTES, '')); ? --EXPECT-- ISO-8859-1 string(18) auml;ouml;uuml; Index: php4/ext/standard/tests/strings/htmlentities8.phpt +++ php4/ext/standard/tests/strings/htmlentities8.phpt --TEST-- htmlentities() test 8 (mbstring / EUC-JP) --INI-- output_handler= mbstring.internal_encoding=EUC-JP --SKIPIF-- ?php function_exists('mb_internal_encoding') or die(skip\n); ? --FILE-- ?php print mb_internal_encoding().\n; var_dump(htmlentities(\xa1\xa2\xa1\xa3\xa1\xa4, ENT_QUOTES, '')); ? --EXPECT-- EUC-JP string(6) ¡¢¡£¡¤ Index: php4/ext/standard/tests/strings/htmlentities9.phpt +++ php4/ext/standard/tests/strings/htmlentities9.phpt --TEST-- htmlentities() test 9 (mbstring / Shift_JIS) --INI-- output_handler= mbstring.internal_encoding=Shift_JIS --SKIPIF-- ?php function_exists('mb_internal_encoding') or die(skip\n); ? --FILE-- ?php print mb_internal_encoding().\n; var_dump(htmlentities(\x81\x41\x81\x42\x81\x43, ENT_QUOTES, '')); ? --EXPECT-- SJIS string(6) ABC -- PHP CVS Mailing List
[PHP-CVS] cvs: php4 /ext/standard html.c
moriyoshi Thu Oct 24 18:04:29 2002 EDT Modified files: /php4/ext/standard html.c Log: Improved determine_charset() to look up SG(default_charset) value Index: php4/ext/standard/html.c diff -u php4/ext/standard/html.c:1.58 php4/ext/standard/html.c:1.59 --- php4/ext/standard/html.c:1.58 Thu Oct 24 17:10:45 2002 +++ php4/ext/standard/html.cThu Oct 24 18:04:28 2002 -18,12 +18,13 +--+ */ -/* $Id: html.c,v 1.58 2002/10/24 21:10:45 moriyoshi Exp $ */ +/* $Id: html.c,v 1.59 2002/10/24 22:04:28 moriyoshi Exp $ */ #include php.h #include reg.h #include html.h #include php_string.h +#include SAPI.h #if HAVE_LOCALE_H #include locale.h #endif -529,7 +530,7 if (charset_hint == NULL) return cs_8859_1; - if (strlen(charset_hint) == 0) { + if ((len = strlen(charset_hint)) == 0) { #if HAVE_MBSTRING /* XXX: Ugly things. Why don't we look for a more sophisticated way? */ switch (MBSTRG(internal_encoding)) { -563,46 +564,45 return cs_gb2312; } #endif - /* try to detect the charset for the locale */ + charset_hint = SG(default_charset); + if (charset_hint == NULL || (len=strlen(charset_hint)) == 0) { + /* try to detect the charset for the locale */ #if HAVE_NL_LANGINFO HAVE_LOCALE_H defined(CODESET) - charset_hint = nl_langinfo(CODESET); + charset_hint = nl_langinfo(CODESET); #endif #if HAVE_LOCALE_H - if (charset_hint == NULL) { - /* try to figure out the charset from the locale */ - char *localename; - char *dot, *at; - - /* lang[_territory][.codeset][modifier] */ - localename = setlocale(LC_CTYPE, NULL); - - dot = strchr(localename, '.'); - if (dot) { - dot++; - /* locale specifies a codeset */ - at = strchr(dot, ''); - if (at) - len = at - dot; - else - len = strlen(dot); - charset_hint = dot; + if (charset_hint == NULL) { + /* try to figure out the charset from the locale */ + char *localename; + char *dot, *at; + + /* lang[_territory][.codeset][modifier] */ + localename = setlocale(LC_CTYPE, NULL); + + dot = strchr(localename, '.'); + if (dot) { + dot++; + /* locale specifies a codeset */ + at = strchr(dot, ''); + if (at) + len = at - dot; + else + len = strlen(dot); + charset_hint = dot; + } else { + /* no explicit name; see if the name itself +* is the charset */ + charset_hint = localename; + len = strlen(charset_hint); + } } else { - /* no explicit name; see if the name itself -* is the charset */ - charset_hint = localename; len = strlen(charset_hint); } - } else - len = strlen(charset_hint); -#else - if (charset_hint) - len = strlen(charset_hint); #endif + } } if (charset_hint) { int found = 0; - if (!len) - len = strlen(charset_hint); /* now walk the charset map and look for the codeset */ for (i = 0; charset_map[i].codeset; i++){ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] cvs: php4 /ext/standard basic_functions.c
iliaa Thu Oct 24 21:06:47 2002 EDT Modified files: /php4/ext/standard basic_functions.c Log: Added a mechanism allowing the disabling of the ability to change certain INI options when safe_mode is enabled. ATM three options are limited: max_execution_time memory_limit child_terminate This patch also fixes bug #17287. Index: php4/ext/standard/basic_functions.c diff -u php4/ext/standard/basic_functions.c:1.536 php4/ext/standard/basic_functions.c:1.537 --- php4/ext/standard/basic_functions.c:1.536 Thu Oct 24 16:04:16 2002 +++ php4/ext/standard/basic_functions.c Thu Oct 24 21:06:46 2002 -17,7 +17,7 +--+ */ -/* $Id: basic_functions.c,v 1.536 2002/10/24 20:04:16 hholzgra Exp $ */ +/* $Id: basic_functions.c,v 1.537 2002/10/25 01:06:46 iliaa Exp $ */ #include php.h #include php_streams.h -2342,6 +2342,18 RETURN_FALSE; } } + } + +#define _CHECK_SAFEMODE_INI(ini, var) strncmp(ini, Z_STRVAL_PP(var), sizeof(ini)) + + /* checks that ensure the user does not overwrite certain ini settings when +safe_mode is enabled */ + if (PG(safe_mode)) { + if (!_CHECK_SAFEMODE_INI(max_execution_time, varname) || + !_CHECK_SAFEMODE_INI(memory_limit, varname) || + !_CHECK_SAFEMODE_INI(child_terminate, varname)) { + zval_dtor(return_value); + RETURN_FALSE; + } } if (zend_alter_ini_entry(Z_STRVAL_PP(varname), Z_STRLEN_PP(varname)+1, Z_STRVAL_PP(new_value), Z_STRLEN_PP(new_value), -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php