Bug #102306 Improper locking in alter_part_normal::try_commit
Submitted: 20 Jan 6:36 Modified: 20 Jan 6:53
Reporter: Zhou Xinjing (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: DDL Severity:S1 (Critical)
Version:8.0 OS:Any
Assigned to: CPU Architecture:Any
Tags: Contribution

[20 Jan 6:36] Zhou Xinjing
Description:
In alter_part_normal::try_commit( storage/innobase/handler/handler0alter.cc:8570 of the latest 8.0.33 release), the call to btr_drop_ahi_for_table is not protected by dict_sys->mutex. This could potentially result in a race condition with other ddl operations on the table.

The problem does not seem to exist in the 5.7 codebase.

How to repeat:
Read the code
[20 Jan 6:37] Zhou Xinjing
A simple fix

(*) I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

Contribution: patch.diff (application/octet-stream, text), 610 bytes.

[20 Jan 6:42] Zhou Xinjing
Correction: 8.0.23
[20 Jan 6:53] MySQL Verification Team
Hello Zhou Xinjing,

Thank you for the report and contribution.

regards,
Umesh