projects
/
ccan
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
e610c8c
)
read_write_all: avoid arithmetic on void pointers.
author
Rusty Russell
<rusty@rustcorp.com.au>
Tue, 22 Mar 2011 01:20:34 +0000
(11:50 +1030)
committer
Rusty Russell
<rusty@rustcorp.com.au>
Tue, 22 Mar 2011 01:20:34 +0000
(11:50 +1030)
ccan/read_write_all/read_write_all.c
patch
|
blob
|
history
diff --git
a/ccan/read_write_all/read_write_all.c
b/ccan/read_write_all/read_write_all.c
index 406bd453e3e63c25b01635363700643e702b0bdf..92efd4298f7edb623225862512491451f0ae5df9 100644
(file)
--- a/
ccan/read_write_all/read_write_all.c
+++ b/
ccan/read_write_all/read_write_all.c
@@
-12,7
+12,7
@@
bool write_all(int fd, const void *data, size_t size)
continue;
if (done <= 0)
return false;
- data
+=
done;
+ data
= (const char *)data +
done;
size -= done;
}
@@
-29,7
+29,7
@@
bool read_all(int fd, void *data, size_t size)
continue;
if (done <= 0)
return false;
- data
+=
done;
+ data
= (char *)data +
done;
size -= done;
}