]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(get_input_fstatus): Use xnmalloc, rather than xmalloc.
authorJim Meyering <jim@meyering.net>
Thu, 6 May 2004 14:23:08 +0000 (14:23 +0000)
committerJim Meyering <jim@meyering.net>
Thu, 6 May 2004 14:23:08 +0000 (14:23 +0000)
src/wc.c

index 091c04386fbb21953fa4e7c3746c0f63f0859025..5a4bec4d6ee1fffef40c9294f2b22e4bec8a3c90 100644 (file)
--- a/src/wc.c
+++ b/src/wc.c
@@ -541,7 +541,7 @@ wc_file (char const *file, struct fstatus *fstatus)
 static struct fstatus *
 get_input_fstatus (int nfiles, char * const *file)
 {
-  struct fstatus *fstatus = xmalloc (nfiles * sizeof *fstatus);
+  struct fstatus *fstatus = xnmalloc (nfiles, sizeof *fstatus);
 
   if (nfiles == 1
       && ((print_lines + print_words + print_chars