[gnome-shell] main: Destroy GjsContext before exit
- From: Philip Chimento <pchimento src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] main: Destroy GjsContext before exit
- Date: Fri, 10 Feb 2017 21:20:14 +0000 (UTC)
commit d017e6749cacf8770726308084eefac3d746a50b
Author: Philip Chimento <philip endlessm com>
Date: Thu Feb 9 18:09:21 2017 -0800
main: Destroy GjsContext before exit
Here are a few places where I missed it before: the GjsContext must be
unrefed before exiting, or it will crash on exit.
https://bugzilla.gnome.org/show_bug.cgi?id=778425
src/gnome-shell-plugin.c | 1 +
src/main.c | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/src/gnome-shell-plugin.c b/src/gnome-shell-plugin.c
index ab5ebec..35b9995 100644
--- a/src/gnome-shell-plugin.c
+++ b/src/gnome-shell-plugin.c
@@ -239,6 +239,7 @@ gnome_shell_plugin_start (MetaPlugin *plugin)
* If there was a generic "hook into bug-buddy for non-C crashes"
* infrastructure, here would be the place to put it.
*/
+ g_object_unref (gjs_context);
exit (1);
}
}
diff --git a/src/main.c b/src/main.c
index c88f046..dbf0e3b 100644
--- a/src/main.c
+++ b/src/main.c
@@ -360,6 +360,7 @@ list_modes (const char *option_name,
if (!gjs_context_eval (context, script, -1, "<main>", &status, NULL))
g_message ("Retrieving list of available modes failed.");
+ g_object_unref (context);
exit (status);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]