PDO MySQL: Handle error during closeCursor()

This commit is contained in:
Nikita Popov 2020-12-09 14:04:30 +01:00
parent 71b5f1446e
commit 23193e89e4
2 changed files with 32 additions and 1 deletions

View file

@ -899,7 +899,8 @@ static int pdo_mysql_stmt_cursor_closer(pdo_stmt_t *stmt) /* {{{ */
while (mysql_more_results(S->H->server)) {
MYSQL_RES *res;
if (mysql_next_result(S->H->server) != 0) {
break;
pdo_mysql_error_stmt(stmt);
PDO_DBG_RETURN(0);
}
res = mysql_store_result(S->H->server);
if (res) {