[MDEV-26573] An improper locking bug due to unreleased lock in the ds_archive.cc Created: 2021-09-08  Updated: 2021-09-15  Resolved: 2021-09-15

Status: Closed
Project: MariaDB Server
Component/s: Server
Affects Version/s: 10.2, 10.3, 10.4, 10.5, 10.6
Fix Version/s: 10.2.41, 10.3.32, 10.4.22, 10.5.13, 10.6.5

Type: Bug Priority: Trivial
Reporter: Ryan Assignee: Vladislav Vaintroub
Resolution: Fixed Votes: 0
Labels: code, performance, server
Environment:

All



 Description   

The lock archive_ctxt->mutex is not released correctly when archive_ctxt->dest_file == NULL in the function archive_open?

https://github.com/MariaDB/server/blob/76f4a78ba2639b5abd01a88b24a3c509c11530ce/extra/mariabackup/ds_archive.cc#L168-L175

Also mentioned in MDEV-26556.



 Comments   
Comment by Vladislav Vaintroub [ 2021-09-15 ]

Ok, that code is not compiled.

Comment by Ryan [ 2021-09-15 ]

@wlad Should be a real bug? Once it is included and compiled in MariaDB.

Comment by Vladislav Vaintroub [ 2021-09-15 ]

it is not compiled. Otherwise, you would point me to the place where ds_archive.cc is compiled, as it would be part of either ADD_LIBRARY or ADD_EXECUTABLE in CMakeLists.txt . it is not there, it is not compiled.
If it was compiled , ds_archive.cc would be somewhere in here https://github.com/MariaDB/server/blob/10.6/extra/mariabackup/CMakeLists.txt#L62

but it is not compiled. So I removed it entirely

Comment by Ryan [ 2021-09-15 ]

OK, thanks

Generated at Thu Feb 08 09:46:19 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.