From: Andrey Hristov Date: Mon, 17 Feb 2014 17:04:01 +0000 (+0200) Subject: remove dead code X-Git-Tag: php-5.6.0alpha3~1^2~67 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3e59f041dab41dab10903a57e0953fe6028e02ab;p=php remove dead code --- diff --git a/ext/mysqlnd/mysqlnd_result.c b/ext/mysqlnd/mysqlnd_result.c index 944999b79c..a4fb9f6cf4 100644 --- a/ext/mysqlnd/mysqlnd_result.c +++ b/ext/mysqlnd/mysqlnd_result.c @@ -1155,24 +1155,6 @@ MYSQLND_METHOD(mysqlnd_res, store_result_fetch_data)(MYSQLND_CONN_DATA * const c */ } /* Overflow ? */ -#if 0 - if (set->row_count) { - /* don't try to allocate more than possible - mnd_XXalloc expects size_t, and it can have narrower range than uint64_t */ - if (set->row_count * meta->field_count * sizeof(zval *) > SIZE_MAX) { - SET_OOM_ERROR(*conn->error_info); - ret = FAIL; - goto end; - } - /* if pecalloc is used valgrind barks gcc version 4.3.1 20080507 (prerelease) [gcc-4_3-branch revision 135036] (SUSE Linux) */ - set->data = mnd_emalloc((size_t)(set->row_count * meta->field_count * sizeof(zval *))); - if (!set->data) { - SET_OOM_ERROR(*conn->error_info); - ret = FAIL; - goto end; - } - memset(set->data, 0, (size_t)(set->row_count * meta->field_count * sizeof(zval *))); - } -#endif MYSQLND_INC_CONN_STATISTIC_W_VALUE(conn->stats, binary_protocol? STAT_ROWS_BUFFERED_FROM_CLIENT_PS: STAT_ROWS_BUFFERED_FROM_CLIENT_NORMAL,