cvs: php4 /ext/interbase interbase.c

From: Date: Fri, 01 Mar 2002 14:03:11 +0000
Subject: cvs: php4 /ext/interbase interbase.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-9546@lists.php.net to get a copy of this message
derick Fri Mar 1 09:03:11 2002 EDT Modified files: /php4/ext/interbase interbase.c Log: - Add support for returning NULL values from Interbase resultsets (Patch by Daniela Mariaschi <mariaschi@libero.it>) Index: php4/ext/interbase/interbase.c diff -u php4/ext/interbase/interbase.c:1.75 php4/ext/interbase/interbase.c:1.76 --- php4/ext/interbase/interbase.c:1.75 Sun Jan 27 10:31:13 2002 +++ php4/ext/interbase/interbase.c Fri Mar 1 09:03:10 2002 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: interbase.c,v 1.75 2002/01/27 15:31:13 aeschbacher Exp $ */ +/* $Id: interbase.c,v 1.76 2002/03/01 14:03:10 derick Exp $ */ /* TODO: Arrays, roles? @@ -594,7 +594,7 @@ php_info_print_table_start(); php_info_print_table_row(2, "Interbase Support", "enabled"); - php_info_print_table_row(2, "Revision", "$Revision: 1.75 $"); + php_info_print_table_row(2, "Revision", "$Revision: 1.76 $"); #ifdef COMPILE_DL_INTERBASE php_info_print_table_row(2, "Dynamic Module", "yes"); #endif @@ -2106,7 +2106,7 @@ switch (Z_TYPE_P(tmp)) { case IS_STRING: add_property_stringl(return_value, var->aliasname, Z_STRVAL_P(tmp), Z_STRLEN_P(tmp), 0); -break; + break; case IS_LONG: add_property_long(return_value, var->aliasname, Z_LVAL_P(tmp)); break; @@ -2116,7 +2116,13 @@ } } efree(tmp); - } /* if not null */ + } else { + if (fetch_type & FETCH_ARRAY) { + add_index_null(return_value, i); + } else { + add_property_null(return_value, var->aliasname); + } + } if ((var->sqltype & ~1) == SQL_ARRAY) { arr_cnt++; }

« previous php.cvs (#9546) next »