3b5b188591
- selinux_check_passwd_access_internal(): respect deny_unknown - Silence -Wstringop-overflow warning from gcc 10.3.1 - Fixed misc compiler and static analyzer findings Resolves: rhbz#1938789
43 lines
1.5 KiB
Diff
43 lines
1.5 KiB
Diff
From c3f4742bb96b7688eb8abd6cc3a89f30aff55f06 Mon Sep 17 00:00:00 2001
|
|
From: =?UTF-8?q?Christian=20G=C3=B6ttsche?= <cgzones@googlemail.com>
|
|
Date: Mon, 3 May 2021 17:10:48 +0200
|
|
Subject: [PATCH] libselinux: avcstat: use standard length modifier for
|
|
unsigned long long
|
|
MIME-Version: 1.0
|
|
Content-Type: text/plain; charset=UTF-8
|
|
Content-Transfer-Encoding: 8bit
|
|
|
|
The format width specifier `L` is only standardized for floating point
|
|
types. Use `ll` for fixed-width data types.
|
|
|
|
Signed-off-by: Christian Göttsche <cgzones@googlemail.com>
|
|
---
|
|
libselinux/utils/avcstat.c | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/libselinux/utils/avcstat.c b/libselinux/utils/avcstat.c
|
|
index da2392870c51..cc9a48dd4c3a 100644
|
|
--- a/libselinux/utils/avcstat.c
|
|
+++ b/libselinux/utils/avcstat.c
|
|
@@ -205,7 +205,7 @@ int main(int argc, char **argv)
|
|
die("unable to parse \'%s\': no data", avcstatfile);
|
|
|
|
if (cumulative || !i)
|
|
- printf("%10Lu %10Lu %10Lu %10Lu %10Lu %10Lu\n",
|
|
+ printf("%10llu %10llu %10llu %10llu %10llu %10llu\n",
|
|
tot.lookups, tot.hits, tot.misses,
|
|
tot.allocations, tot.reclaims, tot.frees);
|
|
else {
|
|
@@ -215,7 +215,7 @@ int main(int argc, char **argv)
|
|
rel.allocations = tot.allocations - last.allocations;
|
|
rel.reclaims = tot.reclaims - last.reclaims;
|
|
rel.frees = tot.frees - last.frees;
|
|
- printf("%10Lu %10Lu %10Lu %10Lu %10Lu %10Lu\n",
|
|
+ printf("%10llu %10llu %10llu %10llu %10llu %10llu\n",
|
|
rel.lookups, rel.hits, rel.misses,
|
|
rel.allocations, rel.reclaims, rel.frees);
|
|
}
|
|
--
|
|
2.32.0.rc1
|
|
|