[gnome-builder] workbench: log context unload errors to console
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] workbench: log context unload errors to console
- Date: Mon, 13 Nov 2017 09:55:14 +0000 (UTC)
commit d75518dc380b1246d1d884c54ad13b53b3e60848
Author: Christian Hergert <chergert redhat com>
Date: Mon Nov 13 01:55:04 2017 -0800
workbench: log context unload errors to console
src/libide/workbench/ide-workbench.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/src/libide/workbench/ide-workbench.c b/src/libide/workbench/ide-workbench.c
index d4b5e78..e9385ae 100644
--- a/src/libide/workbench/ide-workbench.c
+++ b/src/libide/workbench/ide-workbench.c
@@ -96,14 +96,18 @@ ide_workbench_unload_cb (GObject *object,
GAsyncResult *result,
gpointer user_data)
{
- g_autoptr(IdeWorkbench) self = user_data;
IdeContext *context = (IdeContext *)object;
+ g_autoptr(IdeWorkbench) self = user_data;
+ g_autoptr(GError) error = NULL;
g_return_if_fail (IDE_IS_WORKBENCH (self));
- ide_context_unload_finish (context, result, NULL);
+ if (!ide_context_unload_finish (context, result, &error))
+ g_warning ("Failed to unload context: %s", error->message);
gtk_widget_destroy (GTK_WIDGET (self));
+
+ g_clear_object (&self->context);
}
static gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]