From: Denis Kenzior Date: Thu, 14 Jan 2010 16:25:14 +0000 (-0600) Subject: Fix: Make remote disconnect detection work X-Git-Tag: 2.0_alpha~2882 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5d48d4c3b5ed078d42b82b2be066265cc39ef401;p=framework%2Fconnectivity%2Fconnman.git Fix: Make remote disconnect detection work --- diff --git a/gatchat/gatchat.c b/gatchat/gatchat.c index ea17335..8af927e 100644 --- a/gatchat/gatchat.c +++ b/gatchat/gatchat.c @@ -801,7 +801,7 @@ static gboolean received_data(GIOChannel *channel, GIOCondition cond, if (cond & (G_IO_HUP | G_IO_ERR)) return FALSE; - if (err != G_IO_ERROR_NONE && err != G_IO_ERROR_AGAIN) + if (rbytes == 0 && err != G_IO_ERROR_AGAIN) return FALSE; return TRUE;