Skip to content

Commit 5c13587

Browse files
Remove php_mysqli_persistent_helper_once (#7507)
1 parent aa285a0 commit 5c13587

File tree

1 file changed

+1
-21
lines changed

1 file changed

+1
-21
lines changed

ext/mysqli/mysqli.c

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -827,23 +827,6 @@ PHP_RINIT_FUNCTION(mysqli)
827827
}
828828
/* }}} */
829829

830-
#if defined(A0) && defined(MYSQLI_USE_MYSQLND)
831-
static void php_mysqli_persistent_helper_for_every(void *p)
832-
{
833-
mysqlnd_end_psession((MYSQLND *) p);
834-
} /* }}} */
835-
836-
837-
static int php_mysqli_persistent_helper_once(zend_rsrc_list_entry *le)
838-
{
839-
if (le->type == php_le_pmysqli()) {
840-
mysqli_plist_entry *plist = (mysqli_plist_entry *) le->ptr;
841-
zend_ptr_stack_apply(&plist->free_links, php_mysqli_persistent_helper_for_every);
842-
}
843-
return ZEND_HASH_APPLY_KEEP;
844-
} /* }}} */
845-
#endif
846-
847830

848831
/* {{{ PHP_RSHUTDOWN_FUNCTION */
849832
PHP_RSHUTDOWN_FUNCTION(mysqli)
@@ -856,10 +839,7 @@ PHP_RSHUTDOWN_FUNCTION(mysqli)
856839
if (MyG(error_msg)) {
857840
efree(MyG(error_msg));
858841
}
859-
#if defined(A0) && defined(MYSQLI_USE_MYSQLND)
860-
/* psession is being called when the connection is freed - explicitly or implicitly */
861-
zend_hash_apply(&EG(persistent_list), (apply_func_t) php_mysqli_persistent_helper_once);
862-
#endif
842+
863843
return SUCCESS;
864844
}
865845
/* }}} */

0 commit comments

Comments
 (0)