diff options
author | Jim Meyering <jim@meyering.net> | 1995-02-11 13:58:11 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 1995-02-11 13:58:11 +0000 |
commit | 4ef39a33cb05527878b940b229e4b3583fdab31a (patch) | |
tree | 93f2403fd5ddda5023080b88a9037a7c0d4fd27b /src | |
parent | b743f8afc31d1dcf51ad741ea0b37cadd5f5d0e9 (diff) | |
download | coreutils-4ef39a33cb05527878b940b229e4b3583fdab31a.tar.xz |
(copy): Use memset, not bzero.
(copy_simple): Use memcpy, not bcopy.
Diffstat (limited to 'src')
-rw-r--r-- | src/dd.c | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -571,7 +571,7 @@ copy () whatever data we are able to read is followed by zeros. This minimizes data loss. */ if ((conversions_mask & C_SYNC) && (conversions_mask & C_NOERROR)) - bzero (ibuf, input_blocksize); + memset (ibuf, 0, input_blocksize); nread = safe_read (input_fd, ibuf, input_blocksize); @@ -608,7 +608,7 @@ copy () { if (!(conversions_mask & C_NOERROR)) /* If C_NOERROR, we zeroed the block before reading. */ - bzero (ibuf + nread, input_blocksize - nread); + memset (ibuf + nread, 0, input_blocksize - nread); nread = input_blocksize; } } @@ -714,7 +714,7 @@ copy_simple (buf, nread) if (nfree > nread) nfree = nread; - bcopy (start, obuf + oc, nfree); + memcpy (obuf + oc, start, nfree); nread -= nfree; /* Update the number of bytes left to copy. */ start += nfree; @@ -906,6 +906,8 @@ scanargs (argc, argv) optionally multiplied by various values. Return -1 if STR does not represent a number in this format. */ +/* FIXME: use xstrtou?l */ + static int parse_integer (str) char *str; |