cvs: php4(PHP_4_2_0) /ext/oci8 oci8.c
| From: | Thies C. Arntzen | Date: | Sun, 14 Apr 2002 18:28:33 +0000 |
| Subject: | cvs: php4(PHP_4_2_0) /ext/oci8 oci8.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-11140@lists.php.net to get a copy of this message | ||
thies Sun Apr 14 14:28:33 2002 EDT
Modified files: (Branch: PHP_4_2_0)
/php4/ext/oci8 oci8.c
Log:
fix crash bug introduced by last commit (damncvs diff!)
Index: php4/ext/oci8/oci8.c
diff -u php4/ext/oci8/oci8.c:1.169.2.2 php4/ext/oci8/oci8.c:1.169.2.3
--- php4/ext/oci8/oci8.c:1.169.2.2 Sat Apr 13 14:59:38 2002
+++ php4/ext/oci8/oci8.c Sun Apr 14 14:28:32 2002
@@ -20,7 +20,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: oci8.c,v 1.169.2.2 2002/04/13 18:59:38 thies Exp $ */
+/* $Id: oci8.c,v 1.169.2.3 2002/04/14 18:28:32 thies Exp $ */
/* TODO list:
*
@@ -631,7 +631,7 @@
php_info_print_table_start();
php_info_print_table_row(2, "OCI8 Support", "enabled");
- php_info_print_table_row(2, "Revision", "$Revision: 1.169.2.2 $");
+ php_info_print_table_row(2, "Revision", "$Revision: 1.169.2.3 $");
#ifndef PHP_WIN32
php_info_print_table_row(2, "Oracle Version", PHP_OCI8_VERSION );
php_info_print_table_row(2, "Compile-time ORACLE_HOME", PHP_OCI8_DIR );
@@ -697,7 +697,9 @@
if (bind->indicator == -1) { /* NULL */
zval *val = bind->zval;
- *Z_STRVAL_P(val) = '\0'; /* XXX avoid warning in debug mode */
+ if (Z_TYPE_P(val) == IS_STRING && (Z_STRVAL_P(val) != empty_string)) {
+ *Z_STRVAL_P(val) = '\0'; /* XXX avoid warning in debug mode */
+ }
zval_dtor(val);
ZVAL_NULL(val);
} else if (Z_TYPE_P(bind->zval) == IS_STRING && (Z_STRVAL_P(bind->zval) !=
empty_string)) {