Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the missing unlock in extractKeyExistsErr (tidb-6.1) #604

Merged
merged 1 commit into from
Oct 12, 2022

Conversation

sticnarf
Copy link
Collaborator

In #585, I forgot to unlock in all branches in extractKeyExistsErr. So, if it goes into !c.txn.us.HasPresumeKeyNotExists(err.GetKey()) branch, the lock is never released.

Actually, it's unlikely to reach that branch because Op_Insert is only generated when there is a PresumeKeyNotExists flag. The only exception I find is amending transaction. It directly generates Op_Insert entries.

Signed-off-by: Yilin Chen <sticnarf@gmail.com>
@cfzjywxk cfzjywxk merged commit 624e0ed into tikv:tidb-6.1 Oct 12, 2022
sticnarf added a commit to sticnarf/tidb that referenced this pull request Oct 12, 2022
Signed-off-by: Yilin Chen <sticnarf@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants