diff options
author | Johan Hedberg <johan.hedberg@intel.com> | 2011-05-15 01:55:16 +0300 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2011-05-27 10:14:09 -0700 |
commit | 7414d16a24aa82d4a9d369ddf0e2a4fc981d5393 (patch) | |
tree | 4ae0caafb5e6d5f6e7580963f826c5d88bfc5140 | |
parent | ce861145f0ff47fb0c4bd85ad75d5e0a73bbe26d (diff) | |
download | ofono-7414d16a24aa82d4a9d369ddf0e2a4fc981d5393.tar.gz |
btio: Fix unused variable warning
-rw-r--r-- | btio/btio.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/btio/btio.c b/btio/btio.c index a3cf38a3..918eea87 100644 --- a/btio/btio.c +++ b/btio/btio.c @@ -1133,8 +1133,10 @@ gboolean bt_io_accept(GIOChannel *io, BtIOConnect connect, gpointer user_data, } if (!(pfd.revents & POLLOUT)) { - int ret; - ret = read(sock, &c, 1); + if (read(sock, &c, 1) < 0) { + ERROR_FAILED(err, "read", errno); + return FALSE; + } } accept_add(io, connect, user_data, destroy); |