]> git.ipfire.org Git - thirdparty/libcgroup.git/commit
wrapper: fix missing unlock() in cgroup_add_all_controllers()
authorKamalesh Babulal <kamalesh.babulal@oracle.com>
Thu, 15 Jun 2023 09:54:06 +0000 (15:24 +0530)
committerTom Hromatka <tom.hromatka@oracle.com>
Thu, 15 Jun 2023 14:02:05 +0000 (08:02 -0600)
commitbdf36c0bd7171c2fab6ba2ec50cef660aa2eb52f
treeb187f11e15f0d7782e28c56d247da55f90a8e58e
parent82bcebb020c40be21492a6ce752d9ee5bebb5a29
wrapper: fix missing unlock() in cgroup_add_all_controllers()

Fix missing unlock(), reported by Coverity tool:

CID 313906 (#1 of 1): Missing unlock (LOCK)6. missing_unlock: Returning
without unlocking cg_mount_table_lock

add the missing pthread_rwlock_unlock() in the error path of the
cgroup_add_all_controllers()

Fixes: 4124f4d6853a ("wrapper: Add cgroup v2 support to cgroup_add_all_controllers()")
Signed-off-by: Kamalesh Babulal <kamalesh.babulal@oracle.com>
Signed-off-by: Tom Hromatka <tom.hromatka@oracle.com>
src/wrapper.c