From: Seungyoun Ju Date: Sat, 16 Feb 2013 04:26:53 +0000 (+0900) Subject: Function return value is checked X-Git-Tag: 2.1b_release~1^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=695da89bd47708997760980c27ff3af182e548f0;p=platform%2Fcore%2Fconnectivity%2Fmobileap-agent.git Function return value is checked - Issues g_io_channel_read_chars()'s return value is not checked - Fix description g_io_channel_read_chars()'s return value is checked properly Change-Id: I090cf2f9ad556ca96b7d6975f1437f9fcacb5a81 --- diff --git a/src/mobileap_agent.c b/src/mobileap_agent.c index 68f1c67..e643c17 100644 --- a/src/mobileap_agent.c +++ b/src/mobileap_agent.c @@ -348,13 +348,17 @@ static gboolean __hostapd_monitor_cb(GIOChannel *source) } #else GError *err = NULL; + GIOStatus ios; - g_io_channel_read_chars(hostapd_io_channel, buf, + ios = g_io_channel_read_chars(hostapd_io_channel, buf, HOSTAPD_REQ_MAX_LEN, &read, &err); if (err != NULL) { ERR("g_io_channel_read_chars is failed : %s\n", err->message); g_error_free(err); return FALSE; + } else if (ios != G_IO_STATUS_NORMAL) { + ERR("g_io_channel_read_chars is failed : %d\n", ios); + return FALSE; } #endif