cvs: Zend / zend.c zend.h zend_config.nw.h

From: Date: Thu, 02 Jan 2003 14:59:11 +0000
Subject: cvs: Zend / zend.c zend.h zend_config.nw.h
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-748@lists.php.net to get a copy of this message
hyanantha Thu Jan 2 09:59:11 2003 EDT Modified files: /Zend zend.c zend.h zend_config.nw.h Log: NetWare related changes/modifications. Index: Zend/zend.c diff -u Zend/zend.c:1.167 Zend/zend.c:1.168 --- Zend/zend.c:1.167 Tue Dec 31 10:55:00 2002 +++ Zend/zend.c Thu Jan 2 09:59:11 2003 @@ -618,6 +618,24 @@ #ifndef ZTS zend_shutdown_constants(); #endif +#ifdef NETWARE + /* All the below lines added to remove memory leaks! + * They all add up to a big no. Wondering how come it is missed in the original code! + */ + /* Removes a leak of 160 bytes */ + destroy_zend_class(&zend_standard_class_def); /* Destroys the hash tables also */ + /* Removes a leak of 56 bytes */ + zend_hash_destroy(&EG(persistent_list)); + /* Removes a leak of 20,440 bytes */ + zend_hash_destroy(EG(zend_constants)); + /* Removes a leak of 56 bytes */ + free(EG(zend_constants)); + /* Removes a leak of 20,440 bytes */ + zend_hash_destroy(GLOBAL_CONSTANTS_TABLE); + /* Removes a leak of 56 bytes */ + free(GLOBAL_CONSTANTS_TABLE); + /* Removes a leak of 496 bytes */ +#endif /* NetWare */ } Index: Zend/zend.h diff -u Zend/zend.h:1.169 Zend/zend.h:1.170 --- Zend/zend.h:1.169 Tue Dec 31 10:55:00 2002 +++ Zend/zend.h Thu Jan 2 09:59:11 2003 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend.h,v 1.169 2002/12/31 15:55:00 sebastian Exp $ */ +/* $Id: zend.h,v 1.170 2003/01/02 14:59:11 hyanantha Exp $ */ #ifndef ZEND_H #define ZEND_H @@ -43,7 +43,6 @@ # define ZEND_PATHS_SEPARATOR ';' #elif defined(NETWARE) # include "zend_config.nw.h" -# include "acconfig.h" # define ZEND_PATHS_SEPARATOR ';' #elif defined(__riscos__) # include "zend_config.h" @@ -89,7 +88,11 @@ # define RTLD_GLOBAL 0 # endif +#ifndef NETWARE # define DL_LOAD(libname) dlopen(libname, RTLD_LAZY | RTLD_GLOBAL) +#else +# define DL_LOAD(libname) dlopen(libname, RTLD_LAZY | RTLD_LOCAL) +#endif /* NETWARE */ # define DL_UNLOAD dlclose # if DLSYM_NEEDS_UNDERSCORE # define DL_FETCH_SYMBOL(h,s) dlsym((h), "_" s) Index: Zend/zend_config.nw.h diff -u Zend/zend_config.nw.h:1.3 Zend/zend_config.nw.h:1.4 --- Zend/zend_config.nw.h:1.3 Tue Dec 31 10:55:02 2002 +++ Zend/zend_config.nw.h Thu Jan 2 09:59:11 2003 @@ -97,5 +97,6 @@ #define zend_finite(a) (zend_isnan(a) ? 0 : zend_isinf(a) ? 0 : 1) #endif +#undef PTHREADS #endif /* ZEND_CONFIG_NW_H */

« previous php.zend-engine.cvs (#748) next »