[gvfs/gnome-3-14] afp: exit silently if connection closed
- From: Ondrej Holy <oholy src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gvfs/gnome-3-14] afp: exit silently if connection closed
- Date: Thu, 5 Mar 2015 08:08:46 +0000 (UTC)
commit 14369db2a8fc4f2a33e457a766b077ed6e2a3557
Author: Ondrej Holy <oholy redhat com>
Date: Fri Feb 27 10:22:22 2015 +0100
afp: exit silently if connection closed
Commit c15ec62 introduced exit for G_IO_ERROR_CLOSED, however we
should check also for G_IO_ERROR_CONNECTION_CLOSED. Unfortunatelly
this error code was introduced in newer version of GLib then available,
therefore use g_warning instead of g_error to avoid abrt reports.
https://bugzilla.gnome.org/show_bug.cgi?id=710490
daemon/gvfsafpconnection.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/daemon/gvfsafpconnection.c b/daemon/gvfsafpconnection.c
index 2f2958d..e555eb2 100644
--- a/daemon/gvfsafpconnection.c
+++ b/daemon/gvfsafpconnection.c
@@ -1077,12 +1077,12 @@ read_data_cb (GObject *object, GAsyncResult *res, gpointer user_data)
if (g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CLOSED))
{
g_message (_("Host closed connection"));
- exit(0);
}
else
{
- g_error ("FAIL!!! \"%s\"\n", err->message);
+ g_warning ("FAIL!!! \"%s\"\n", err->message);
}
+ exit (0);
}
dispatch_reply (afp_connection);
@@ -1118,12 +1118,12 @@ read_dsi_header_cb (GObject *object, GAsyncResult *res, gpointer user_data)
if (g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CLOSED))
{
g_message (_("Host closed connection"));
- exit(0);
}
else
{
- g_error ("FAIL!!! \"%s\"\n", err->message);
+ g_warning ("FAIL!!! \"%s\"\n", err->message);
}
+ exit (0);
}
dsi_header = &priv->read_dsi_header;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]