e2fsprogs
e2fsprogs copied to clipboard
improper locking due to unreleased locks
Hi, developers, thank you for your checking. It seems two locks CACHE_MTX
and BOUNCE_MTX
are not released correctly when retval = flush_cached_blocks(channel, data, FLUSH_NOLOCK)
returns true in the function unix_set_blksize
?
https://github.com/tytso/e2fsprogs/blob/f158f8962ed7e884fa168f354c488f3afa3eb6db/lib/ext2fs/unix_io.c#L957-L968
Looks like a deadlock is going to happen.
@hifi521 yes, there are possible deadlocks due to the missing releases of these two locks.