From 6d61f17dd64de9b030adf0e0ab0ed1b56b999603 Mon Sep 17 00:00:00 2001 From: Christian Brauner Date: Sat, 20 Oct 2018 12:04:33 +0200 Subject: [PATCH] coverity: #1426130 Bad bit shift operation Fixes: commit b5b12b9e759 ("criu: add feature check capability") Cc: Adrian Reber Signed-off-by: Christian Brauner --- src/lxc/criu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lxc/criu.c b/src/lxc/criu.c index c8cd449de..60cdb17e8 100644 --- a/src/lxc/criu.c +++ b/src/lxc/criu.c @@ -695,7 +695,7 @@ bool __criu_check_feature(uint64_t *features_to_check) return false; } - while (current_bit < sizeof(uint64_t) * 8) { + while (current_bit < (sizeof(uint64_t) * 8 - 1)) { /* only test requested features */ if (!(features & (1ULL << current_bit))) { /* skip this */ -- 2.47.2