summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--gatchat/gatchat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gatchat/gatchat.c b/gatchat/gatchat.c
index ea17335e..8af927ed 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;