summaryrefslogtreecommitdiff
path: root/src/md5sum.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2006-08-16 19:36:46 +0000
committerPaul Eggert <eggert@cs.ucla.edu>2006-08-16 19:36:46 +0000
commitb96f5ea4925854db9eae61f98a7ec44568ecae7d (patch)
tree913918a48168b6e77f64b65f61e9d42b791f1ab2 /src/md5sum.c
parentf048f049e7dd531e207c630088d050c376b39feb (diff)
downloadcoreutils-b96f5ea4925854db9eae61f98a7ec44568ecae7d.tar.xz
Fix bugs when printing plurals of numbers that are not
unsigned long int values. * src/system.h (select_plural): New function. * src/md5sum.c (digest_check): Use select_plural to avoid bug. * src/uptime.c (print_uptime): Likewise. * src/dd.c (print_stats): Likewise. Also, don't use ngettext to print a floating point number, as reducing to 0 or 1 doesn't work for some languages. Instead, just use "s" for seconds since it doesn't need a plural form.
Diffstat (limited to 'src/md5sum.c')
-rw-r--r--src/md5sum.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/md5sum.c b/src/md5sum.c
index 1ecd672b5..a8ce1cf27 100644
--- a/src/md5sum.c
+++ b/src/md5sum.c
@@ -563,7 +563,7 @@ digest_check (const char *checkfile_name)
" listed file could not be read",
"WARNING: %" PRIuMAX " of %" PRIuMAX
" listed files could not be read",
- n_properly_formatted_lines),
+ select_plural (n_properly_formatted_lines)),
n_open_or_read_failures, n_properly_formatted_lines);
if (n_mismatched_checksums != 0)
@@ -575,7 +575,7 @@ digest_check (const char *checkfile_name)
" computed checksum did NOT match",
"WARNING: %" PRIuMAX " of %" PRIuMAX
" computed checksums did NOT match",
- n_computed_checksums),
+ select_plural (n_computed_checksums)),
n_mismatched_checksums, n_computed_checksums);
}
}