CVS update: php3/functions

From: Date: Thu, 10 Sep 1998 18:29:16 +0000
Subject: CVS update: php3/functions
Groups: php.dev 
Request: Send a blank email to php-dev+get-909@lists.php.net to get a copy of this message
Date: Thursday September 10, 1998 @ 14:29 Author: ssb Update of /repository/php3/functions In directory asf:/u2/tmp/cvs-serv26942 Modified Files: oci8.c Log Message: Renamed oci8_get_pval to oci8_make_pval for clarity. Fixed OCIFetchInto(). Now you can use isset() to test for NULL columns from it. Index: php3/functions/oci8.c diff -c php3/functions/oci8.c:1.9 php3/functions/oci8.c:1.10 *** php3/functions/oci8.c:1.9 Thu Sep 10 13:58:00 1998 --- php3/functions/oci8.c Thu Sep 10 14:29:15 1998 *************** *** 27,33 **** +----------------------------------------------------------------------+ */ ! /* $Id: oci8.c,v 1.9 1998/09/10 17:58:00 ssb Exp $ */ #include "php.h" #include "internal_functions.h" --- 27,33 ---- +----------------------------------------------------------------------+ */ ! /* $Id: oci8.c,v 1.10 1998/09/10 18:29:15 ssb Exp $ */ #include "php.h" #include "internal_functions.h" *************** *** 133,138 **** --- 133,139 ---- static oci8_connection *oci8_get_conn(int, const char *, HashTable *, HashTable *); static oci8_statement *oci8_get_stmt(int, const char *, HashTable *); static oci8_out_column *oci8_get_col(oci8_statement *, int, char *); + static pval *oci8_make_pval(oci8_out_column *, char *); static int oci8_parse(oci8_connection *, text *, ub4, HashTable *); static int oci8_execute(oci8_statement *, char *); static int oci8_fetch(oci8_statement *, ub4, char *); *************** *** 473,479 **** static pval * ! oci8_get_pval(oci8_out_column *column, char *func) { pval *value = OCI8_CALLOC(1,sizeof(pval)); size_t size; --- 474,480 ---- static pval * ! oci8_make_pval(oci8_out_column *column, char *func) { pval *value = OCI8_CALLOC(1,sizeof(pval)); size_t size; *************** *** 1065,1071 **** if (outcol == NULL) { RETURN_FALSE; } ! ret = oci8_get_pval(outcol, "OCIResult"); if (ret == NULL) { RETVAL_FALSE; } else { --- 1066,1072 ---- if (outcol == NULL) { RETURN_FALSE; } ! ret = oci8_make_pval(outcol, "OCIResult"); if (ret == NULL) { RETVAL_FALSE; } else { *************** *** 1138,1151 **** for (i = 0; i < statement->ncolumns; i++) { column = oci8_get_col(statement, i + 1, "OCIFetchInto"); ! if (column == NULL) { continue; } ! element = oci8_get_pval(column, "OCIFetchInto"); ! _php3_hash_index_update(array->value.ht, i, (void *)&element, sizeof(pval), NULL); } ! } /* }}} */ --- 1139,1152 ---- for (i = 0; i < statement->ncolumns; i++) { column = oci8_get_col(statement, i + 1, "OCIFetchInto"); ! if (column == NULL || column->indicator == -1) { continue; } ! element = oci8_make_pval(column, "OCIFetchInto"); ! _php3_hash_index_update(array->value.ht, i, (void *)element, sizeof(pval), NULL); } ! RETVAL_LONG(statement->ncolumns); } /* }}} */ -- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net For help: php-dev-help@lists.php.net

« previous php.dev (#909) next »