diff options
author | Ruediger Meier | 2016-02-22 11:58:05 +0100 |
---|---|---|
committer | Ruediger Meier | 2016-03-07 23:16:04 +0100 |
commit | fdbd7bb94051bce49a40b0e055bfa21755de3b1c (patch) | |
tree | b4525048d811b8a7bf1d6574922995fa25fb8a9f /disk-utils/mkswap.c | |
parent | wipefs, sfdisk: include libgen.h for basename(3p) (diff) | |
download | kernel-qcow2-util-linux-fdbd7bb94051bce49a40b0e055bfa21755de3b1c.tar.gz kernel-qcow2-util-linux-fdbd7bb94051bce49a40b0e055bfa21755de3b1c.tar.xz kernel-qcow2-util-linux-fdbd7bb94051bce49a40b0e055bfa21755de3b1c.zip |
misc: again fixing many printf format strings
This is again a huge patch regarding printf format strings to
fix compiler warnings seen on clang/OSX.
I'm trying to follow these rules strictly:
#type #format #cast
uintmax_t %ju -
intmax_t %jd -
uint64_t PRIu64 -
int64_t PRId64 -
size_t %zu -
ssize_t %zd -
ino_t %ju (uintmax_t)
off_t %jd (intmax_t)
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
Diffstat (limited to 'disk-utils/mkswap.c')
-rw-r--r-- | disk-utils/mkswap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/disk-utils/mkswap.c b/disk-utils/mkswap.c index ae02de569..52ee8c65d 100644 --- a/disk-utils/mkswap.c +++ b/disk-utils/mkswap.c @@ -443,7 +443,7 @@ int main(int argc, char **argv) else if (ctl.npages > sz && !ctl.force) errx(EXIT_FAILURE, _("error: " - "size %llu KiB is larger than device size %ju KiB"), + "size %llu KiB is larger than device size %"PRIu64" KiB"), ctl.npages * (ctl.pagesize / 1024), sz * (ctl.pagesize / 1024)); if (ctl.npages < MIN_GOODPAGES) @@ -489,7 +489,7 @@ int main(int argc, char **argv) sz = (ctl.npages - ctl.nbadpages - 1) * ctl.pagesize; strsz = size_to_human_string(SIZE_SUFFIX_SPACE | SIZE_SUFFIX_3LETTER, sz); - printf(_("Setting up swapspace version %d, size = %s (%ju bytes)\n"), + printf(_("Setting up swapspace version %d, size = %s (%"PRIu64" bytes)\n"), version, strsz, sz); free(strsz); |