diff options
author | Sami Kerola | 2014-03-08 22:43:28 +0100 |
---|---|---|
committer | Karel Zak | 2014-03-26 10:36:18 +0100 |
commit | a3030b8ad36fc34208514df604f9ea9744b765b7 (patch) | |
tree | 7edf702123c436b42fbe616a454a24fc927b406e /misc-utils/mcookie.c | |
parent | mcookie: allow --file option be defined multiple times (diff) | |
download | kernel-qcow2-util-linux-a3030b8ad36fc34208514df604f9ea9744b765b7.tar.gz kernel-qcow2-util-linux-a3030b8ad36fc34208514df604f9ea9744b765b7.tar.xz kernel-qcow2-util-linux-a3030b8ad36fc34208514df604f9ea9744b765b7.zip |
mcookie: use same variable type consistently
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'misc-utils/mcookie.c')
-rw-r--r-- | misc-utils/mcookie.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/misc-utils/mcookie.c b/misc-utils/mcookie.c index 9bfa9759c..3f9403405 100644 --- a/misc-utils/mcookie.c +++ b/misc-utils/mcookie.c @@ -39,9 +39,9 @@ enum { }; /* The basic function to hash a file */ -static off_t hash_file(struct MD5Context *ctx, int fd) +static size_t hash_file(struct MD5Context *ctx, int fd) { - off_t count = 0; + size_t count = 0; ssize_t r; unsigned char buf[BUFFERSIZE]; @@ -74,7 +74,7 @@ static void randomness_from_files(char **files, int nfiles, struct MD5Context *ctx, int verbose) { int fd, i; - int count = 0; + size_t count = 0; for (i = 0; i < nfiles; i++) { if (files[i][0] == '-' && !files[i][1]) @@ -88,8 +88,8 @@ static void randomness_from_files(char **files, int nfiles, count = hash_file(ctx, fd); if (verbose) fprintf(stderr, - P_("Got %d byte from %s\n", - "Got %d bytes from %s\n", count), + P_("Got %zu byte from %s\n", + "Got %zu bytes from %s\n", count), count, files[i]); if (fd != STDIN_FILENO) |