filters: Utilize ACQUIRE_LOCK_FOR_CURRENT_SCOPE
commit975dab14b3245e82481ddcb43d1ef64c2b99442c
authorEric Blake <eblake@redhat.com>
Tue, 23 Apr 2019 19:06:35 +0000 (23 14:06 -0500)
committerRichard W.M. Jones <rjones@redhat.com>
Wed, 24 Apr 2019 08:03:43 +0000 (24 09:03 +0100)
tree4e03b1674fa0a4ffb8d7b2e8e5f36f40260585ae
parentd9a9daf096e4267df4ae7cb760a2be190ac3286e
filters: Utilize ACQUIRE_LOCK_FOR_CURRENT_SCOPE

Now that cleanup.h is in common code, we can use it in our filters
where it makes sense. Many uses of pthread_mutex_unlock() are not
function-wide, and over small enough snippets of code as to be easier
to read when left as-is; but when the scope is indeed function-wide or
across multiple exit paths, it is nicer to use the macro for automatic
unlock.

Signed-off-by: Eric Blake <eblake@redhat.com>
filters/log/Makefile.am
filters/log/log.c
filters/readahead/Makefile.am
filters/readahead/readahead.c