diff options
author | markm <markm@FreeBSD.org> | 2002-07-31 16:52:16 +0000 |
---|---|---|
committer | markm <markm@FreeBSD.org> | 2002-07-31 16:52:16 +0000 |
commit | 7726f590e76ed6b044f3241153ee1fea90aed1a6 (patch) | |
tree | a69345ef05c6754c27e84651c8b012db33df2ec1 /bin/cp/utils.c | |
parent | 80ff821584cb31d63941a00fd81d828ebe5d50a9 (diff) | |
download | FreeBSD-src-7726f590e76ed6b044f3241153ee1fea90aed1a6.zip FreeBSD-src-7726f590e76ed6b044f3241153ee1fea90aed1a6.tar.gz |
Fix some easy WARNS.
Diffstat (limited to 'bin/cp/utils.c')
-rw-r--r-- | bin/cp/utils.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/bin/cp/utils.c b/bin/cp/utils.c index 364f983..ab92dfc 100644 --- a/bin/cp/utils.c +++ b/bin/cp/utils.c @@ -140,10 +140,10 @@ copy_file(FTSENT *entp, int dne) for (bufp = p, wresid = fs->st_size; ; bufp += wcount, wresid -= (size_t)wcount) { wcount = write(to_fd, bufp, wresid); - if (wcount >= wresid || wcount <= 0) + if (wcount >= (ssize_t)wresid || wcount <= 0) break; } - if (wcount != wresid) { + if (wcount != (ssize_t)wresid) { warn("%s", to.p_path); rval = 1; } @@ -160,10 +160,10 @@ copy_file(FTSENT *entp, int dne) for (bufp = buf, wresid = rcount; ; bufp += wcount, wresid -= wcount) { wcount = write(to_fd, bufp, wresid); - if (wcount >= wresid || wcount <= 0) + if (wcount >= (ssize_t)wresid || wcount <= 0) break; } - if (wcount != wresid) { + if (wcount != (ssize_t)wresid) { warn("%s", to.p_path); rval = 1; break; |