tree-wide: replace FLAGS_SET(..., 1 << v) with BIT_SET(..., v)
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
#include <sys/mman.h>
|
||||
|
||||
#include "alloc-util.h"
|
||||
#include "bitfield.h"
|
||||
#include "errno-util.h"
|
||||
#include "fd-util.h"
|
||||
#include "hashmap.h"
|
||||
@@ -109,7 +110,7 @@ static Window* window_unlink(Window *w) {
|
||||
}
|
||||
|
||||
for (unsigned i = 0; i < _MMAP_CACHE_CATEGORY_MAX; i++)
|
||||
if (FLAGS_SET(w->flags, 1u << i))
|
||||
if (BIT_SET(w->flags, i))
|
||||
assert_se(TAKE_PTR(m->windows_by_category[i]) == w);
|
||||
|
||||
return LIST_REMOVE(windows, w->fd->windows, w);
|
||||
@@ -193,7 +194,7 @@ static void category_detach_window(MMapCache *m, MMapCacheCategory c) {
|
||||
if (!w)
|
||||
return; /* Nothing attached. */
|
||||
|
||||
assert(FLAGS_SET(w->flags, 1u << c));
|
||||
assert(BIT_SET(w->flags, c));
|
||||
w->flags &= ~(1u << c);
|
||||
|
||||
if (WINDOW_IS_UNUSED(w)) {
|
||||
|
||||
Reference in New Issue
Block a user