summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-02-12 10:55:07 -0700
committerJens Axboe <axboe@kernel.dk>2018-02-12 10:55:07 -0700
commitf2cd91604af170e972438c461a40230e266a57d9 (patch)
tree904c5d6b41f4e5e3a5f9eba9f84514308ca551ec
parente244616690aa6c9d0e5aed74860a55715d03b052 (diff)
downloadfio-f2cd91604af170e972438c461a40230e266a57d9.tar.gz
fio-f2cd91604af170e972438c461a40230e266a57d9.tar.bz2
debug: fix inverted logic in fio_did_warn()fio-3.4
Fixes: 5ec3bc5401f3 ("init: add global 'warned' state") Signed-off-by: Jens Axboe <axboe@kernel.dk>
-rw-r--r--debug.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/debug.h b/debug.h
index a2b6fa67..ba622146 100644
--- a/debug.h
+++ b/debug.h
@@ -31,11 +31,10 @@ extern unsigned int fio_debug_jobno, *fio_debug_jobp, *fio_warned;
static inline bool fio_did_warn(unsigned int mask)
{
- if (!(*fio_warned & mask)) {
- *fio_warned |= mask;
+ if (*fio_warned & mask)
return true;
- }
+ *fio_warned |= mask;
return false;
}