[gnome-builder/gnome-builder-3-18] buffer: log errors from g_file_monitor_file()
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/gnome-builder-3-18] buffer: log errors from g_file_monitor_file()
- Date: Tue, 13 Oct 2015 07:35:32 +0000 (UTC)
commit ea7b1d9d66930c88c2423d47e44cba3bddbc7c0e
Author: Christian Hergert <christian hergert me>
Date: Sat Oct 3 16:10:00 2015 -0700
buffer: log errors from g_file_monitor_file()
We weren't even using the error before.
Stash it, log it, free it. (Technologic)
libide/ide-buffer.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/libide/ide-buffer.c b/libide/ide-buffer.c
index d52f0f4..c54c920 100644
--- a/libide/ide-buffer.c
+++ b/libide/ide-buffer.c
@@ -827,7 +827,7 @@ ide_buffer__file_notify_file (IdeBuffer *self,
{
GError *error = NULL;
- priv->file_monitor = g_file_monitor_file (gfile, G_FILE_MONITOR_NONE, NULL, NULL);
+ priv->file_monitor = g_file_monitor_file (gfile, G_FILE_MONITOR_NONE, NULL, &error);
if (priv->file_monitor != NULL)
{
@@ -837,7 +837,7 @@ ide_buffer__file_notify_file (IdeBuffer *self,
self,
G_CONNECT_SWAPPED);
}
- else
+ else if (error != NULL)
{
g_debug ("Failed to create GFileMonitor: %s", error->message);
g_clear_error (&error);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]