summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2011-02-09 01:55:08 +0000
committerBastien Nocera <hadess@hadess.net>2011-02-12 02:14:24 +0000
commit9342606a43239cda9420bc1c0090988006f50404 (patch)
tree780a719256bf9081fa0cc990c36b5e4c76db8350 /src
parentf3e2132a165d855310280569d7da7ae3a50b573c (diff)
main: Don't crash if the plugins weren't loaded
If we exit before the plugins engine was setup, please don't crash.
Diffstat (limited to 'src')
-rw-r--r--src/totem-object.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/totem-object.c b/src/totem-object.c
index 2a8108c9..922a1cb2 100644
--- a/src/totem-object.c
+++ b/src/totem-object.c
@@ -955,7 +955,8 @@ totem_object_action_exit (TotemObject *totem)
char *page_id;
/* Shut down the plugins first, allowing them to display modal dialogues (etc.) without threat of being killed from another thread */
- totem_plugins_engine_shut_down (totem->engine);
+ if (totem != NULL && totem->engine != NULL)
+ totem_plugins_engine_shut_down (totem->engine);
/* Exit forcefully if we can't do the shutdown in 10 seconds */
g_thread_create ((GThreadFunc) totem_action_wait_force_exit,