From 8788f30c129100be3efda3902f0268a6c63cdf0b Mon Sep 17 00:00:00 2001 From: "Thies C. Arntzen" Date: Mon, 5 Jul 1999 08:49:13 +0000 Subject: [PATCH] fixed mem-leak --- ext/oci8/oci8.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index f3d3faa967..a5afbf1211 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -1032,7 +1032,7 @@ oci8_parse(oci8_connection *connection, char *query, int len, HashTable *list) } } -#if 0 /* testing */ +#if 1 /* testing */ { ub4 prefetch = 512*1024; @@ -1041,7 +1041,7 @@ oci8_parse(oci8_connection *connection, char *query, int len, HashTable *list) "OCIAttrSet OCI_ATTR_PREFETCH_MEMORY", OCIAttrSet(statement->pStmt, OCI_HTYPE_STMT, - 512*1024, //&prefetch, + &prefetch, 0, OCI_ATTR_PREFETCH_MEMORY, statement->pError)); @@ -3170,6 +3170,8 @@ PHP_FUNCTION(oci8_fetchinto) if ((mode & OCI_NUM) || (! (mode & OCI_ASSOC))) { /* OCI_NUM is default */ oci8_make_pval(element,statement,column, "OCIFetchInto",mode); #if PHP_API_VERSION >= 19990421 + element->is_ref = 0; + element->refcount = 1; _php3_hash_index_update(array->value.ht, i, (void *)&element, sizeof(pval*), NULL); #else _php3_hash_index_update(array->value.ht, i, (void *)element, sizeof(pval), NULL); -- 2.50.1