From e2868b57885dac8a36593e2154c808038adc4cef Mon Sep 17 00:00:00 2001 From: Ilia Alshanetsky Date: Sat, 18 Jan 2003 19:41:56 +0000 Subject: Removed pointless memory allocation checks. --- ext/mssql/php_mssql.c | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) (limited to 'ext/mssql/php_mssql.c') diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c index fa244f0c16..72b639b50c 100644 --- a/ext/mssql/php_mssql.c +++ b/ext/mssql/php_mssql.c @@ -1280,9 +1280,7 @@ static void php_mssql_fetch_hash(INTERNAL_FUNCTION_PARAMETERS, int result_type) RETURN_FALSE; } - if (array_init(return_value)==FAILURE) { - RETURN_FALSE; - } + array_init(return_value); for (i=0; inum_fields; i++) { if (Z_TYPE(result->data[result->cur_row][i]) != IS_NULL) { @@ -1838,15 +1836,8 @@ PHP_FUNCTION(mssql_init) statement=NULL; statement = ecalloc(1,sizeof(mssql_statement)); - - if (statement!=NULL) { - statement->link = mssql_ptr; - statement->executed=FALSE; - } - else { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to allocate statement"); - RETURN_FALSE; - } + statement->link = mssql_ptr; + statement->executed=FALSE; statement->id = zend_list_insert(statement,le_statement); -- cgit v1.2.1