summaryrefslogtreecommitdiffstats
path: root/src/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util.c')
-rw-r--r--src/util.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/util.c b/src/util.c
index 964e36f..96b99c1 100644
--- a/src/util.c
+++ b/src/util.c
@@ -296,7 +296,7 @@ int copy_fd(int sfd, int dfd, off_t l) {
while (l > 0) {
off_t n;
- size_t m = MIN(l, BUFSIZE);
+ m = MIN(l, BUFSIZE);
if ((n = loop_read(sfd, buf, m)) != m) {
@@ -761,13 +761,13 @@ ssize_t loop_write(int fd, const void *d, size_t l) {
ssize_t r;
if ((r = write(fd, p, l)) <= 0)
- return p-(uint8_t*)d > 0 ? p-(uint8_t*) d : r;
+ return p-(const uint8_t*)d > 0 ? p-(const uint8_t*) d : r;
p += r;
l -= r;
}
- return p-(uint8_t*) d;
+ return p-(const uint8_t*) d;
}
char *snprint_off(char *s, size_t l, off_t off) {