From c0d910d50632c5dd05006984dbfb37a84b318507 Mon Sep 17 00:00:00 2001 From: Niels Dossche <7771979+nielsdos@users.noreply.github.com> Date: Sun, 9 Feb 2025 18:55:14 +0100 Subject: [PATCH] Get rid of always-false intern checks These checks are always false because we're receiving a valid zend_object. --- ext/sqlite3/sqlite3.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c index 4fed2742bce..7d5b3eaee6d 100644 --- a/ext/sqlite3/sqlite3.c +++ b/ext/sqlite3/sqlite3.c @@ -2163,10 +2163,6 @@ static void php_sqlite3_object_free_storage(zend_object *object) /* {{{ */ php_sqlite3_func *func; php_sqlite3_collation *collation; - if (!intern) { - return; - } - /* Release function_name from authorizer */ if (ZEND_FCC_INITIALIZED(intern->authorizer_fcc)) { zend_fcc_dtor(&intern->authorizer_fcc); @@ -2262,10 +2258,6 @@ static void php_sqlite3_stmt_object_free_storage(zend_object *object) /* {{{ */ { php_sqlite3_stmt *intern = php_sqlite3_stmt_from_obj(object); - if (!intern) { - return; - } - if (intern->bound_params) { zend_hash_destroy(intern->bound_params); FREE_HASHTABLE(intern->bound_params); @@ -2289,10 +2281,6 @@ static void php_sqlite3_result_object_free_storage(zend_object *object) /* {{{ * { php_sqlite3_result *intern = php_sqlite3_result_from_obj(object); - if (!intern) { - return; - } - sqlite3result_clear_column_names_cache(intern); if (!Z_ISNULL(intern->stmt_obj_zval)) {