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

index 2c34c11bc9bf0d74480f5cd6593a3f08c14b4183..dd38bac8a077e793704987ac4feb3dc8402b3e5d 100644 (file)
@@ -1201,7 +1201,7 @@ do_wipefd (int fd, char const *qname, struct isaac_state *s,
     }
 
   /* Allocate pass array */
-  passarray = xmalloc (flags->n_iterations * sizeof (int));
+  passarray = xnmalloc (flags->n_iterations, sizeof *passarray);
 
   size = flags->size;
   if (size == -1)