From 517debc389414cce263ab1dbbb5a9df02a76a464 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Tue, 28 May 2019 12:17:26 +0200 Subject: readprofile: be more explicit with used types [cppcheck] Signed-off-by: Karel Zak --- sys-utils/readprofile.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys-utils/readprofile.c b/sys-utils/readprofile.c index 1d484252a..132386437 100644 --- a/sys-utils/readprofile.c +++ b/sys-utils/readprofile.c @@ -263,9 +263,9 @@ int main(int argc, char **argv) size_t i; for (p = buf + 1; p < buf + entries; p++) { - if (*p & ~0U << (sizeof(*buf) * 4)) + if (*p & ~0U << ((unsigned) sizeof(*buf) * 4U)) big++; - if (*p & ((1 << (sizeof(*buf) * 4)) - 1)) + if (*p & ((1U << ((unsigned) sizeof(*buf) * 4U)) - 1U)) small++; } if (big > small) { -- cgit v1.2.3-55-g7522