diff options
author | Kimmo Hämäläinen <kimmo.hamalainen@nokia.com> | 2010-03-16 13:55:13 -0400 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2010-03-16 13:55:13 -0400 |
commit | e28c0ece17f0cfac1d18527604a67bcba7c3d2cc (patch) | |
tree | 34f805782f19f0e23d25a50ef330a73e0108fba2 | |
parent | 922c6f3285c429af364a44cbc19950fff92bb62b (diff) | |
download | dbus-e28c0ece17f0cfac1d18527604a67bcba7c3d2cc.tar.gz |
[dbus-spawn] Use correct sign values for variables
read() returns a signed value, whereas the byte count is unsigned.
Signed-off-by: Colin Walters <walters@verbum.org>
-rw-r--r-- | dbus/dbus-spawn.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/dbus/dbus-spawn.c b/dbus/dbus-spawn.c index c08f9278..91054154 100644 --- a/dbus/dbus-spawn.c +++ b/dbus/dbus-spawn.c @@ -74,8 +74,8 @@ read_ints (int fd, while (TRUE) { - size_t chunk; - ssize_t to_read; + ssize_t chunk; + size_t to_read; to_read = sizeof (int) * n_ints_in_buf - bytes; @@ -129,9 +129,9 @@ read_pid (int fd, while (TRUE) { - size_t chunk; - ssize_t to_read; - + ssize_t chunk; + size_t to_read; + to_read = sizeof (pid_t) - bytes; if (to_read == 0) |