git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e82d864
)
guestfsd.c: don't perform arithmetic on void pointers
author
Jim Meyering
<meyering@redhat.com>
Mon, 17 Aug 2009 07:24:47 +0000
(09:24 +0200)
committer
Jim Meyering
<meyering@redhat.com>
Mon, 17 Aug 2009 09:40:24 +0000
(11:40 +0200)
* daemon/guestfsd.c (xread, xwrite): Use char* pointers instead.
daemon/guestfsd.c
patch
|
blob
|
history
diff --git
a/daemon/guestfsd.c
b/daemon/guestfsd.c
index
fad49fb
..
ad3ce15
100644
(file)
--- a/
daemon/guestfsd.c
+++ b/
daemon/guestfsd.c
@@
-273,9
+273,10
@@
sysroot_path (const char *path)
}
int
-xwrite (int sock, const void *buf, size_t len)
+xwrite (int sock, const void *
v_
buf, size_t len)
{
int r;
+ const char *buf = v_buf;
while (len > 0) {
r = write (sock, buf, len);
@@
-291,9
+292,10
@@
xwrite (int sock, const void *buf, size_t len)
}
int
-xread (int sock, void *buf, size_t len)
+xread (int sock, void *
v_
buf, size_t len)
{
int r;
+ char *buf = v_buf;
while (len > 0) {
r = read (sock, buf, len);