packages: php-pecl-runkit/php-pecl-runkit.spec, php-pecl-runkit/branch.diff...

glen glen at pld-linux.org
Sun Jun 6 16:35:48 CEST 2010


Author: glen                         Date: Sun Jun  6 14:35:48 2010 GMT
Module: packages                      Tag: HEAD
---- Log message:
- add branch.diff

---- Files affected:
packages/php-pecl-runkit:
   php-pecl-runkit.spec (1.17 -> 1.18) , branch.diff (NONE -> 1.1)  (NEW), branch.sh (NONE -> 1.1)  (NEW), php-pecl-runkit-php52.patch (1.2 -> NONE)  (REMOVED)

---- Diffs:

================================================================
Index: packages/php-pecl-runkit/php-pecl-runkit.spec
diff -u packages/php-pecl-runkit/php-pecl-runkit.spec:1.17 packages/php-pecl-runkit/php-pecl-runkit.spec:1.18
--- packages/php-pecl-runkit/php-pecl-runkit.spec:1.17	Wed Jun  2 17:53:33 2010
+++ packages/php-pecl-runkit/php-pecl-runkit.spec	Sun Jun  6 16:35:43 2010
@@ -1,22 +1,20 @@
 # $Revision$, $Date$
-%define		_modname	runkit
-%define		_status		beta
-Summary:	%{_modname} - mangle with user defined functions and classes
-Summary(pl.UTF-8):	%{_modname} - obróbka zdefiniowanych przez użytkownika funkcji i klas
-Name:		php-pecl-%{_modname}
+%define		modname	runkit
+%define		status		beta
+Summary:	%{modname} - mangle with user defined functions and classes
+Summary(pl.UTF-8):	%{modname} - obróbka zdefiniowanych przez użytkownika funkcji i klas
+Name:		php-pecl-%{modname}
 Version:	0.9
 Release:	5
 License:	PHP
 Group:		Development/Languages/PHP
-Source0:	http://pecl.php.net/get/%{_modname}-%{version}.tgz
+Source0:	http://pecl.php.net/get/%{modname}-%{version}.tgz
 # Source0-md5:	855786f79a3803972b04e44c32cece8d
-Patch0:		%{name}-php52.patch
+Patch0:		branch.diff
 URL:		http://pecl.php.net/package/runkit/
 BuildRequires:	php-devel >= 4:5.2
 BuildRequires:	rpmbuild(macros) >= 1.344
 %{?requires_php_extension}
-Requires:	php-common >= 4:5.0.4
-Obsoletes:	php-pear-%{_modname}
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -24,7 +22,7 @@
 customized superglobal variables for general purpose use. Execute code
 in restricted environment (sandboxing).
 
-In PECL status of this extension is: %{_status}.
+In PECL status of this extension is: %{status}.
 
 %description -l pl.UTF-8
 Zastępowanie, zmiana nazwy lub usuwanie zdefiniowanych przez
@@ -32,13 +30,12 @@
 ogólnego użytku. Wykonywanie danego kodu w ograniczonym środowisku
 (sandbox).
 
-To rozszerzenie ma w PECL status: %{_status}.
+To rozszerzenie ma w PECL status: %{status}.
 
 %prep
-%setup -q -c
-mv %{_modname}-%{version}/* .
-rmdir %{_modname}-%{version}
-%patch0 -p1
+%setup -qc
+mv %{modname}-%{version}/* .
+%patch0 -p0
 
 %build
 phpize
@@ -49,10 +46,10 @@
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT{%{php_sysconfdir}/conf.d,%{php_extensiondir}}
 
-install modules/%{_modname}.so $RPM_BUILD_ROOT%{php_extensiondir}
-cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{_modname}.ini
-; Enable %{_modname} extension module
-extension=%{_modname}.so
+install modules/%{modname}.so $RPM_BUILD_ROOT%{php_extensiondir}
+cat <<'EOF' > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/%{modname}.ini
+; Enable %{modname} extension module
+extension=%{modname}.so
 EOF
 
 %clean
@@ -69,8 +66,8 @@
 %files
 %defattr(644,root,root,755)
 %doc README
-%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{_modname}.ini
-%attr(755,root,root) %{php_extensiondir}/%{_modname}.so
+%config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/%{modname}.ini
+%attr(755,root,root) %{php_extensiondir}/%{modname}.so
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -78,6 +75,9 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.18  2010/06/06 14:35:43  glen
+- add branch.diff
+
 Revision 1.17  2010/06/02 15:53:33  glen
 - release 5
 

================================================================
Index: packages/php-pecl-runkit/branch.diff
diff -u /dev/null packages/php-pecl-runkit/branch.diff:1.1
--- /dev/null	Sun Jun  6 16:35:48 2010
+++ packages/php-pecl-runkit/branch.diff	Sun Jun  6 16:35:43 2010
@@ -0,0 +1,915 @@
+Index: package2.xml
+===================================================================
+Cannot display: file marked as a binary type.
+svn:mime-type = application/xml
+Index: runkit_methods.c
+===================================================================
+--- runkit_methods.c	(.../tags/RELEASE_0_9)
++++ runkit_methods.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -373,7 +375,7 @@
+ 								  char *sclass, int sclass_len, char *sfunc, int sfunc_len TSRMLS_DC)
+ {
+ 	zend_class_entry *dce, *sce;
+-	zend_function dfe, *sfe;
++	zend_function dfe, *sfe, *dfeInHashTable;
+ 
+ 	if (php_runkit_fetch_class_method(sclass, sclass_len, sfunc, sfunc_len, &sce, &sfe TSRMLS_CC) == FAILURE) {
+ 		return FAILURE;
+@@ -395,12 +397,12 @@
+ 	dfe.common.scope = dce;
+ #endif
+ 
+-	if (zend_hash_add(&dce->function_table, dfunc, dfunc_len + 1, &dfe, sizeof(zend_function), NULL) == FAILURE) {
++	if (zend_hash_add(&dce->function_table, dfunc, dfunc_len + 1, &dfe, sizeof(zend_function), &dfeInHashTable) == FAILURE) {
+ 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Error adding method to class %s::%s()", dclass, dfunc);
+ 		return FAILURE;
+ 	}
+ 
+-	PHP_RUNKIT_ADD_MAGIC_METHOD(dce, dfunc, &dfe);
++	PHP_RUNKIT_ADD_MAGIC_METHOD(dce, dfunc, dfeInHashTable);
+ 
+ 	zend_hash_apply_with_arguments(EG(class_table), (apply_func_args_t)php_runkit_update_children_methods, 5, dce, dce, &dfe, dfunc, dfunc_len);
+ 
+
+Property changes on: runkit_methods.c
+___________________________________________________________________
+Modified: cvs2svn:cvs-rev
+   - 1.6
+   + 1.8
+
+Index: runkit_props.c
+===================================================================
+--- runkit_props.c	(.../tags/RELEASE_0_9)
++++ runkit_props.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -124,8 +126,14 @@
+ 	ALLOC_ZVAL(copyval);
+ 	*copyval = *value;
+ 	zval_copy_ctor(copyval);
++
++#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION >= 3) || (PHP_MAJOR_VERSION >= 6)
++	Z_SET_REFCOUNT_P(copyval, 1);
++	Z_UNSET_ISREF_P(copyval);
++#else
+ 	copyval->refcount = 1;
+ 	copyval->is_ref = 0;
++#endif
+ 
+ 	if (zend_hash_add(&ce->default_properties, key, key_len + 1, &copyval, sizeof(zval *), NULL) == FAILURE) {
+ 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to add default property to class definition");
+
+Property changes on: runkit_props.c
+___________________________________________________________________
+Modified: cvs2svn:cvs-rev
+   - 1.4
+   + 1.6
+
+Index: runkit_sandbox_parent.c
+===================================================================
+--- runkit_sandbox_parent.c	(.../tags/RELEASE_0_9)
++++ runkit_sandbox_parent.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -699,14 +701,13 @@
+    * Class Definition *
+    ******************** */
+ 
+-static
+-	ZEND_BEGIN_ARG_INFO_EX(php_runkit_require_two_args, 0, 0, 2)
+-		ZEND_ARG_PASS_INFO(0)
+-		ZEND_ARG_PASS_INFO(0)
+-	ZEND_END_ARG_INFO()
++ZEND_BEGIN_ARG_INFO_EX(arginfo_runkit_sandbox_parent__call, 0, 0, 2)
++	ZEND_ARG_PASS_INFO(0)
++	ZEND_ARG_PASS_INFO(0)
++ZEND_END_ARG_INFO()
+ 
+-static function_entry php_runkit_sandbox_parent_functions[] = {
+-	PHP_ME(Runkit_Sandbox_Parent,		__call,						php_runkit_require_two_args,		ZEND_ACC_PUBLIC)
++static zend_function_entry php_runkit_sandbox_parent_functions[] = {
++	PHP_ME(Runkit_Sandbox_Parent,		__call,						arginfo_runkit_sandbox_parent__call,ZEND_ACC_PUBLIC)
+ 	/* Language Constructs */
+ 	PHP_ME(Runkit_Sandbox_Parent,		eval,						NULL,								ZEND_ACC_PUBLIC)
+ 	PHP_ME(Runkit_Sandbox_Parent,		include,					NULL,								ZEND_ACC_PUBLIC)
+
+Property changes on: runkit_sandbox_parent.c
+___________________________________________________________________
+Modified: cvs2svn:cvs-rev
+   - 1.6
+   + 1.9
+
+Index: runkit_functions.c
+===================================================================
+--- runkit_functions.c	(.../tags/RELEASE_0_9)
++++ runkit_functions.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -28,7 +30,7 @@
+ 	ptr = EG(current_execute_data);
+ 
+ 	while (ptr) {
+-		if (ptr->op_array->opcodes == op_array->opcodes) {
++		if (ptr->op_array && ptr->op_array->opcodes == op_array->opcodes) {
+ 			return FAILURE;
+ 		}
+ 		ptr = ptr->prev_execute_data;
+@@ -134,6 +136,8 @@
+ 	while (i > 0) {
+ 		i--;
+ 		dupvars[i].name = estrdup(fe->op_array.vars[i].name);
++		dupvars[i].name_len = fe->op_array.vars[i].name_len;
++		dupvars[i].hash_value = fe->op_array.vars[i].hash_value;
+ 	}
+ 	fe->op_array.vars = dupvars;
+ #endif
+@@ -376,7 +380,7 @@
+ 	}
+ 
+ 	if (zend_hash_add(EG(function_table), dfunc, dfunc_len + 1, &func, sizeof(zend_function), NULL) == FAILURE) {
+-		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to add refernce to new function name %s()", dfunc);
++		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to add reference to new function name %s()", dfunc);
+ 		zend_function_dtor(fe);
+ 		RETURN_FALSE;
+ 	}
+
+Property changes on: runkit_functions.c
+___________________________________________________________________
+Modified: cvs2svn:cvs-rev
+   - 1.8
+   + 1.11
+
+Index: runkit_import.c
+===================================================================
+--- runkit_import.c	(.../tags/RELEASE_0_9)
++++ runkit_import.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -21,79 +23,65 @@
+ #ifdef PHP_RUNKIT_MANIPULATION
+ /* {{{ php_runkit_import_functions
+  */
+-static int php_runkit_import_functions(int original_num_functions TSRMLS_DC)
++static int php_runkit_import_functions(HashTable *function_table, long flags TSRMLS_DC)
+ {
+ 	HashPosition pos;
+-	zend_function **fe_array;
+-	int i, func = 0, func_count = (zend_hash_num_elements(EG(function_table)) - original_num_functions);
++	int i, func_count = zend_hash_num_elements(function_table);
+ 
+-	fe_array = ecalloc(sizeof(zend_function*) * func_count, 0);
+-
+-	zend_hash_internal_pointer_end_ex(EG(function_table), &pos);
+-	for(i = zend_hash_num_elements(EG(function_table)); i > original_num_functions; i--) {
++	zend_hash_internal_pointer_reset_ex(function_table, &pos);
++	for(i = 0; i < func_count; i++) {
+ 		zend_function *fe = NULL;
+ 		char *key;
+ 		int key_len, type;
+ 		long idx;
++		zend_bool add_function = 1;
+ 
+-		zend_hash_get_current_data_ex(EG(function_table), (void**)&fe, &pos);
+-		PHP_RUNKIT_FUNCTION_ADD_REF(fe);
+-		fe_array[func++] = fe;
++		zend_hash_get_current_data_ex(function_table, (void**)&fe, &pos);
+ 
+ 		if (((type = zend_hash_get_current_key_ex(EG(function_table), &key, &key_len, &idx, 0, &pos)) != HASH_KEY_NON_EXISTANT) && 
+ 			fe && fe->type == ZEND_USER_FUNCTION) {
+-
+-			if (type == HASH_KEY_IS_STRING) {
+-				if (zend_hash_del(EG(function_table), key, key_len) == FAILURE) {
+-					goto err_exit;
++		
++			if (flags & PHP_RUNKIT_IMPORT_OVERRIDE) {
++				if (type == HASH_KEY_IS_STRING) {
++					if (zend_hash_del(EG(function_table), key, key_len) == FAILURE) {
++						php_error_docref(NULL TSRMLS_CC, E_WARNING, "Inconsistency cleaning up import environment");
++						return FAILURE;
++					}
++				} else {
++					if (zend_hash_index_del(EG(function_table), idx) == FAILURE) {
++						php_error_docref(NULL TSRMLS_CC, E_WARNING, "Inconsistency cleaning up import environment");
++						return FAILURE;
++					}
+ 				}
+ 			} else {
+-				if (zend_hash_index_del(EG(function_table), idx) == FAILURE) {
+-					goto err_exit;
+-				}
++				add_function = 0;
+ 			}
+-		} else {
+-			goto err_exit;
+ 		}
+-		zend_hash_move_backwards_ex(EG(function_table), &pos);
+-	}
+ 
+-	while (func >= 0) {
+-		zend_function *fe = fe_array[func];
++		if (add_function) {
++			PHP_RUNKIT_FUNCTION_ADD_REF(fe);
+ 
+-		if (fe) {
++
+ 			char *lcase = estrdup(fe->common.function_name);
+ 			int lcase_len = strlen(lcase);
+ 
+ 			php_strtolower(lcase, lcase_len);
+ 			if (zend_hash_add(EG(function_table), lcase, lcase_len + 1, fe, sizeof(zend_function), NULL) == FAILURE) {
+-				php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failure importing %s()", fe->common.function_name); 
++				php_error_docref(NULL TSRMLS_CC, E_WARNING, "Failure importing %s()", fe->common.function_name);
+ #ifdef ZEND_ENGINE_2
+ 				destroy_zend_function(fe TSRMLS_CC);
+ #else
+-				destroy_zend_function(fe);
++				destroy_end_function(fe);
+ #endif
+ 				efree(lcase);
++				return FAILURE;
+ 			}
++			efree(lcase);
+ 		}
+-		func--;
++		zend_hash_move_forward_ex(function_table, &pos);
+ 	}
+ 
+ 	return SUCCESS;
+-err_exit:
+-	while (func >= 0) {
+-		if (fe_array[func]) {
+-#ifdef ZEND_ENGINE_2
+-			destroy_zend_function(fe_array[func] TSRMLS_CC);
+-#else
+-			destroy_zend_function(fe_array[func]);
+-#endif
+-		}
+-		func--;
+-	}
+-	efree(fe_array);
+-	php_error_docref(NULL TSRMLS_CC, E_WARNING, "Inconsistency cleaning up import environment");
+-	return FAILURE;
+ }
+ /* }}} */
+ 
+@@ -226,7 +214,9 @@
+ 		if (zend_hash_get_current_key_ex(&ce->default_properties, &key, &key_len, &idx, 0, &pos) == HASH_KEY_IS_STRING) {
+ 			char *cname = NULL, *pname = key;
+ 
+-#ifdef ZEND_ENGINE_2
++#ifdef ZEND_ENGINE_2_2
++			zend_unmangle_property_name(key, key_len - 1, &cname, &pname);
++#elif defined(ZEND_ENGINE_2)
+ 			zend_unmangle_property_name(key, &cname, &pname);
+ #endif
+ 			if (zend_hash_exists(&dce->default_properties, key, key_len)) {
+@@ -260,21 +250,20 @@
+ 
+ /* {{{ php_runkit_import_classes
+  */
+-static int php_runkit_import_classes(int original_num_classes, long flags TSRMLS_DC)
++static int php_runkit_import_classes(HashTable *class_table, long flags TSRMLS_DC)
+ {
+ 	HashPosition pos;
+-	int i;
++	int i, class_count;
+ 
+-	/* Pop the "new" classes off the class table */
+-	zend_hash_internal_pointer_end_ex(EG(class_table), &pos);
+-	for(i = zend_hash_num_elements(EG(class_table));
+-		i > original_num_classes; i--) {
++	class_count = zend_hash_num_elements(class_table);
++	zend_hash_internal_pointer_reset_ex(class_table, &pos);
++	for(i = 0; i < class_count; i++) {
+ 		zend_class_entry *ce = NULL;
+ 		char *key;
+ 		int key_len, type;
+ 		long idx;
+ 
+-		zend_hash_get_current_data_ex(EG(class_table), (void**)&ce, &pos);
++		zend_hash_get_current_data_ex(class_table, (void**)&ce, &pos);
+ #ifdef ZEND_ENGINE_2
+ 		if (ce) {
+ 			ce = *((zend_class_entry**)ce);
+@@ -289,13 +278,6 @@
+ 			ce && ce->type == ZEND_USER_CLASS) {
+ 			zend_class_entry *dce;
+ 
+-			if (ce->name_length == key_len - 1) {
+-				/* If their lengths are the same it's all the evidence we need that their names are the same.
+-					If their names are the same its because this class was freshly declared, no need for aggregation. */
+-				continue;
+-			}
+-			/* Otherwise aggregate methods/consts/props from temp class to real one then demolish it */
+-
+ 			/* We can clobber the temp class's name, it'll be freed soon anyway */
+ 			php_strtolower(ce->name, ce->name_length);
+ 
+@@ -319,15 +301,15 @@
+ 				php_runkit_import_class_props(dce, ce, (flags & PHP_RUNKIT_IMPORT_OVERRIDE) TSRMLS_CC);
+ 			}
+ 
+-			zend_hash_move_backwards_ex(EG(class_table), &pos);
++			zend_hash_move_forward_ex(class_table, &pos);
+ 
+ 			if (type == HASH_KEY_IS_STRING) {
+-				if (zend_hash_del(EG(class_table), key, key_len) == FAILURE) {
++				if (zend_hash_del(class_table, key, key_len) == FAILURE) {
+ 					php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to remove temporary version of class %s", ce->name);
+ 					continue;
+ 				}
+ 			} else {
+-				if (zend_hash_index_del(EG(class_table), idx) == FAILURE) {
++				if (zend_hash_index_del(class_table, idx) == FAILURE) {
+ 					php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to remove temporary version of class %s", ce->name);
+ 					continue;
+ 				}
+@@ -404,11 +386,11 @@
+ 	Similar to include(), but doesn't execute root op_array, and allows pre-existing functions/methods to be overridden */
+ PHP_FUNCTION(runkit_import)
+ {
+-	int original_num_functions = zend_hash_num_elements(EG(function_table));
+-	int original_num_classes = zend_hash_num_elements(EG(class_table));
+ 	zend_op_array *new_op_array;
+ 	zval *filename;
+ 	long flags = PHP_RUNKIT_IMPORT_CLASS_METHODS;
++	HashTable *current_class_table, *class_table, *current_function_table, *function_table;
++
+ 	zend_op_array *(*local_compile_filename)(int type, zval *filename TSRMLS_DC) = compile_filename;
+ 
+ 	if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z|l", &filename, &flags) == FAILURE) {
+@@ -422,11 +404,27 @@
+ 		 * to be used */
+ 		local_compile_filename = php_runkit_compile_filename;
+ 	}
++
++	class_table = (HashTable *) emalloc(sizeof(HashTable));
++	zend_hash_init_ex(class_table, 10, NULL, ZEND_CLASS_DTOR, 0, 0);
++	function_table = (HashTable *) emalloc(sizeof(HashTable));
++	zend_hash_init_ex(function_table, 100, NULL, ZEND_FUNCTION_DTOR, 0, 0);	
++
++	current_class_table = CG(class_table);
++	CG(class_table) = class_table;
++	current_function_table = CG(function_table);
++	CG(function_table) = function_table;
++
+ 	new_op_array = local_compile_filename(ZEND_INCLUDE, filename TSRMLS_CC);
++	
++	CG(class_table) = current_class_table;
++	CG(function_table) = current_function_table;
++	
+ 	if (!new_op_array) {
+ 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Import Failure");
+ 		RETURN_FALSE;
+ 	}
++
+ 	/* We never really needed the main loop opcodes to begin with */
+ #ifdef ZEND_ENGINE_2
+ 	destroy_op_array(new_op_array TSRMLS_CC);
+@@ -436,13 +434,18 @@
+ 	efree(new_op_array);
+ 
+ 	if (flags & PHP_RUNKIT_IMPORT_FUNCTIONS) {
+-		php_runkit_import_functions(original_num_functions TSRMLS_CC);
++		php_runkit_import_functions(function_table, flags TSRMLS_CC);
+ 	}
+ 
+ 	if (flags & PHP_RUNKIT_IMPORT_CLASSES) {
+-		php_runkit_import_classes(original_num_classes, flags TSRMLS_CC);
++		php_runkit_import_classes(class_table, flags TSRMLS_CC);
+ 	}
+ 
++	zend_hash_destroy(class_table);
++	efree(class_table);
++	zend_hash_destroy(function_table);
++	efree(function_table);
++
+ 	RETURN_TRUE;
+ }
+ /* }}} */
+
+Property changes on: runkit_import.c
+___________________________________________________________________
+Modified: cvs2svn:cvs-rev
+   - 1.8
+   + 1.11
+
+Index: runkit_constants.c
+===================================================================
+--- runkit_constants.c	(.../tags/RELEASE_0_9)
++++ runkit_constants.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -197,8 +199,15 @@
+ 	ALLOC_ZVAL(copyval);
+ 	*copyval = *value;
+ 	zval_copy_ctor(copyval);
++
++#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION >= 3) || (PHP_MAJOR_VERSION >= 6)
++	Z_SET_REFCOUNT_P(copyval, 1);
++	Z_UNSET_ISREF_P(copyval);
++#else
+ 	copyval->refcount = 1;
+ 	copyval->is_ref = 0;
++#endif
++
+ 	if (zend_hash_add(&ce->constants_table, constname, constname_len + 1, &copyval, sizeof(zval *), NULL) == FAILURE) {
+ 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to add constant to class definition");
+ 		zval_ptr_dtor(&copyval);
+
+Property changes on: runkit_constants.c
+___________________________________________________________________
+Modified: cvs2svn:cvs-rev
+   - 1.3
+   + 1.5
+
+Index: package.xml
+===================================================================
+Cannot display: file marked as a binary type.
+svn:mime-type = application/xml
+
+Property changes on: package.xml
+___________________________________________________________________
+Deleted: svn:mime-type
+   - application/xml
+
+Index: runkit.c
+===================================================================
+--- runkit.c	(.../tags/RELEASE_0_9)
++++ runkit.c	(.../trunk)
+@@ -2,6 +2,8 @@
+   +----------------------------------------------------------------------+
+   | PHP Version 5                                                        |
+   +----------------------------------------------------------------------+
++  | Copyright (c) 1997-2006 The PHP Group                                |
++  +----------------------------------------------------------------------+
+   | This source file is subject to version 3.0 of the PHP license,       |
+   | that is bundled with this package in the file LICENSE, and is        |
+   | available through the world-wide-web at the following url:           |
+@@ -58,15 +60,20 @@
<<Diff was trimmed, longer than 597 lines>>

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/php-pecl-runkit/php-pecl-runkit.spec?r1=1.17&r2=1.18&f=u



More information about the pld-cvs-commit mailing list