summaryrefslogtreecommitdiff
path: root/storage/innobase/lock
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-10-22 13:27:18 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2020-10-22 13:27:18 +0300
commit46957a6a77518b579c6c8e1345666f84a5a59455 (patch)
treec0e463f14123cd09bb4d5854d32577e44b3a9827 /storage/innobase/lock
parent1619ae899099c4934f3b5919b2398c95a7cacc94 (diff)
parente3d692aa092a76415ce1ce0e9662338873d84abb (diff)
downloadmariadb-git-46957a6a77518b579c6c8e1345666f84a5a59455.tar.gz
Merge 10.3 into 10.4
Diffstat (limited to 'storage/innobase/lock')
-rw-r--r--storage/innobase/lock/lock0lock.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/storage/innobase/lock/lock0lock.cc b/storage/innobase/lock/lock0lock.cc
index 3d18e2e2473..81525680a33 100644
--- a/storage/innobase/lock/lock0lock.cc
+++ b/storage/innobase/lock/lock0lock.cc
@@ -2143,12 +2143,12 @@ lock_grant_and_move_on_page(ulint rec_fold, ulint space, ulint page_no)
lock = previous->hash;
}
- ut_ad(!lock->trx->is_wsrep());
ut_ad(previous->hash == lock || previous == lock);
/* Grant locks if there are no conflicting locks ahead.
Move granted locks to the head of the list. */
while (lock) {
/* If the lock is a wait lock on this page, and it does not need to wait. */
+ ut_ad(!lock->trx->is_wsrep());
if (lock_get_wait(lock)
&& lock->un_member.rec_lock.space == space
&& lock->un_member.rec_lock.page_no == page_no
@@ -4071,11 +4071,10 @@ lock_grant_and_move_on_rec(
}
lock = previous->hash;
}
- ut_ad(!lock->trx->is_wsrep());
/* Grant locks if there are no conflicting locks ahead.
Move granted locks to the head of the list. */
- for (;lock != NULL;) {
-
+ while (lock) {
+ ut_ad(!lock->trx->is_wsrep());
/* If the lock is a wait lock on this page, and it does not need to wait. */
if (lock->un_member.rec_lock.space == space
&& lock->un_member.rec_lock.page_no == page_no