tony2001 Tue Jul 31 19:21:08 2007 UTC Modified files: (Branch: PHP_5_2) /php-src NEWS /php-src/ext/oci8 oci8.c oci8_collection.c oci8_interface.c oci8_lob.c oci8_statement.c php_oci8_int.h Log: MFH: fix #42134 (oci_error() returns false after oci_new_collection() fails) http://cvs.php.net/viewvc.cgi/php-src/NEWS?r1=1.2027.2.547.2.866&r2=1.2027.2.547.2.867&diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.547.2.866 php-src/NEWS:1.2027.2.547.2.867 --- php-src/NEWS:1.2027.2.547.2.866 Tue Jul 31 15:41:31 2007 +++ php-src/NEWS Tue Jul 31 19:21:08 2007 @@ -74,6 +74,8 @@ length). (Ilia) - Fixed bug #42135 (Second call of session_start() causes creation of SID). (Ilia) +- Fixed bug #42134 (oci_error() returns false after oci_new_collection() + fails). (Tony) - Fixed Bug #42112 (deleting a node produces memory corruption). (Rob) - Fixed Bug #42107 (sscanf broken when using %2$s format parameters). (Jani) - Fixed bug #42090 (json_decode causes segmentation fault). (Hannes) http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8.c?r1=1.269.2.16.2.34&r2=1.269.2.16.2.35&diff_format=u Index: php-src/ext/oci8/oci8.c diff -u php-src/ext/oci8/oci8.c:1.269.2.16.2.34 php-src/ext/oci8/oci8.c:1.269.2.16.2.35 --- php-src/ext/oci8/oci8.c:1.269.2.16.2.34 Wed Jul 18 15:10:42 2007 +++ php-src/ext/oci8/oci8.c Tue Jul 31 19:21:08 2007 @@ -26,7 +26,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: oci8.c,v 1.269.2.16.2.34 2007/07/18 15:10:42 sixd Exp $ */ +/* $Id: oci8.c,v 1.269.2.16.2.35 2007/07/31 19:21:08 tony2001 Exp $ */ /* TODO * * file://localhost/www/docs/oci10/ociaahan.htm#423823 - implement lob_empty() with OCI_ATTR_LOBEMPTY @@ -674,7 +674,7 @@ php_info_print_table_start(); php_info_print_table_row(2, "OCI8 Support", "enabled"); php_info_print_table_row(2, "Version", "1.2.3"); - php_info_print_table_row(2, "Revision", "$Revision: 1.269.2.16.2.34 $"); + php_info_print_table_row(2, "Revision", "$Revision: 1.269.2.16.2.35 $"); snprintf(buf, sizeof(buf), "%ld", OCI_G(num_persistent)); php_info_print_table_row(2, "Active Persistent Connections", buf); @@ -1832,3 +1832,12 @@ #endif #endif /* HAVE_OCI8 */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8_collection.c?r1=1.5.2.3.2.6&r2=1.5.2.3.2.7&diff_format=u Index: php-src/ext/oci8/oci8_collection.c diff -u php-src/ext/oci8/oci8_collection.c:1.5.2.3.2.6 php-src/ext/oci8/oci8_collection.c:1.5.2.3.2.7 --- php-src/ext/oci8/oci8_collection.c:1.5.2.3.2.6 Wed Jul 18 15:10:42 2007 +++ php-src/ext/oci8/oci8_collection.c Tue Jul 31 19:21:08 2007 @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: oci8_collection.c,v 1.5.2.3.2.6 2007/07/18 15:10:42 sixd Exp $ */ +/* $Id: oci8_collection.c,v 1.5.2.3.2.7 2007/07/31 19:21:08 tony2001 Exp $ */ @@ -55,7 +55,8 @@ collection->connection = connection; collection->collection = NULL; - + zend_list_addref(collection->connection->rsrc_id); + /* get type handle by name */ PHP_OCI_CALL_RETURN(connection->errcode, OCITypeByName, ( @@ -741,3 +742,12 @@ } /* }}} */ #endif /* HAVE_OCI8 */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8_interface.c?r1=1.8.2.7.2.10&r2=1.8.2.7.2.11&diff_format=u Index: php-src/ext/oci8/oci8_interface.c diff -u php-src/ext/oci8/oci8_interface.c:1.8.2.7.2.10 php-src/ext/oci8/oci8_interface.c:1.8.2.7.2.11 --- php-src/ext/oci8/oci8_interface.c:1.8.2.7.2.10 Wed Jul 18 15:10:42 2007 +++ php-src/ext/oci8/oci8_interface.c Tue Jul 31 19:21:08 2007 @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: oci8_interface.c,v 1.8.2.7.2.10 2007/07/18 15:10:42 sixd Exp $ */ +/* $Id: oci8_interface.c,v 1.8.2.7.2.11 2007/07/31 19:21:08 tony2001 Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -2169,3 +2169,12 @@ #endif #endif /* HAVE_OCI8 */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8_lob.c?r1=1.7.2.6.2.13&r2=1.7.2.6.2.14&diff_format=u Index: php-src/ext/oci8/oci8_lob.c diff -u php-src/ext/oci8/oci8_lob.c:1.7.2.6.2.13 php-src/ext/oci8/oci8_lob.c:1.7.2.6.2.14 --- php-src/ext/oci8/oci8_lob.c:1.7.2.6.2.13 Wed Jul 18 15:10:42 2007 +++ php-src/ext/oci8/oci8_lob.c Tue Jul 31 19:21:08 2007 @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: oci8_lob.c,v 1.7.2.6.2.13 2007/07/18 15:10:42 sixd Exp $ */ +/* $Id: oci8_lob.c,v 1.7.2.6.2.14 2007/07/31 19:21:08 tony2001 Exp $ */ @@ -69,6 +69,8 @@ descriptor = ecalloc(1, sizeof(php_oci_descriptor)); descriptor->type = type; + descriptor->connection = connection; + zend_list_addref(descriptor->connection->rsrc_id); PHP_OCI_CALL_RETURN(OCI_G(errcode), OCIDescriptorAlloc, (connection->env, (dvoid*)&(descriptor->descriptor), descriptor->type, (size_t) 0, (dvoid **) 0)); @@ -79,8 +81,6 @@ return NULL; } - descriptor->connection = connection; - PHP_OCI_REGISTER_RESOURCE(descriptor, le_descriptor); descriptor->lob_current_position = 0; @@ -895,3 +895,12 @@ } /* }}} */ #endif /* HAVE_OCI8 */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/oci8_statement.c?r1=1.7.2.14.2.26&r2=1.7.2.14.2.27&diff_format=u Index: php-src/ext/oci8/oci8_statement.c diff -u php-src/ext/oci8/oci8_statement.c:1.7.2.14.2.26 php-src/ext/oci8/oci8_statement.c:1.7.2.14.2.27 --- php-src/ext/oci8/oci8_statement.c:1.7.2.14.2.26 Wed Jul 18 15:10:42 2007 +++ php-src/ext/oci8/oci8_statement.c Tue Jul 31 19:21:08 2007 @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: oci8_statement.c,v 1.7.2.14.2.26 2007/07/18 15:10:42 sixd Exp $ */ +/* $Id: oci8_statement.c,v 1.7.2.14.2.27 2007/07/31 19:21:08 tony2001 Exp $ */ #ifdef HAVE_CONFIG_H @@ -107,6 +107,7 @@ statement->connection = connection; statement->has_data = 0; statement->nested = 0; + zend_list_addref(statement->connection->rsrc_id); if (OCI_G(default_prefetch) > 0) { php_oci_statement_set_prefetch(statement, OCI_G(default_prefetch) TSRMLS_CC); @@ -1587,3 +1588,12 @@ } /* }}} */ #endif /* HAVE_OCI8 */ + +/* + * Local variables: + * tab-width: 4 + * c-basic-offset: 4 + * End: + * vim600: noet sw=4 ts=4 fdm=marker + * vim<600: noet sw=4 ts=4 + */ http://cvs.php.net/viewvc.cgi/php-src/ext/oci8/php_oci8_int.h?r1=1.11.2.6.2.19&r2=1.11.2.6.2.20&diff_format=u Index: php-src/ext/oci8/php_oci8_int.h diff -u php-src/ext/oci8/php_oci8_int.h:1.11.2.6.2.19 php-src/ext/oci8/php_oci8_int.h:1.11.2.6.2.20 --- php-src/ext/oci8/php_oci8_int.h:1.11.2.6.2.19 Mon Jul 9 09:08:59 2007 +++ php-src/ext/oci8/php_oci8_int.h Tue Jul 31 19:21:08 2007 @@ -25,7 +25,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_oci8_int.h,v 1.11.2.6.2.19 2007/07/09 09:08:59 tony2001 Exp $ */ +/* $Id: php_oci8_int.h,v 1.11.2.6.2.20 2007/07/31 19:21:08 tony2001 Exp $ */ #if HAVE_OCI8 # ifndef PHP_OCI8_INT_H @@ -263,7 +263,6 @@ #define PHP_OCI_REGISTER_RESOURCE(resource, le_resource) \ do { \ resource->id = ZEND_REGISTER_RESOURCE(NULL, resource, le_resource); \ - zend_list_addref(resource->connection->rsrc_id); \ } while (0) #define PHP_OCI_ZVAL_TO_CONNECTION(zval, connection) \
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php