diff options
author | Christian Persch <chpe@gnome.org> | 2009-10-20 18:01:12 (GMT) |
---|---|---|
committer | Christian Persch <chpe@gnome.org> | 2009-10-20 18:01:12 (GMT) |
commit | ba540cc933501c25ee8caddc9225b782e0fec8ae (patch) | |
tree | 29cfba43ea877f519563e633ce9f8a306228c021 /shell/ev-application.c | |
parent | ebcb31119d3e0fcb586cc36ee1e94b12dcd40bb0 (diff) |
shell: Don't crash when we don't have a DBUS connection
When getting the DBUS fails, we don't create the applications->windows
hash table, but were still looking things up in it.
Diffstat (limited to 'shell/ev-application.c')
-rw-r--r-- | shell/ev-application.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/shell/ev-application.c b/shell/ev-application.c index 69a5a73..24ef1e0 100644 --- a/shell/ev-application.c +++ b/shell/ev-application.c @@ -667,7 +667,8 @@ ev_application_open_uri_in_window (EvApplication *application, ev_window_open_uri (ev_window, uri, dest, mode, search_string); #ifdef ENABLE_DBUS - if (!g_hash_table_lookup (application->windows, ev_window)) { + if (application->windows != NULL && + !g_hash_table_lookup (application->windows, ev_window)) { g_hash_table_insert (application->windows, ev_window, g_strdup (uri)); g_signal_connect_swapped (ev_window, "destroy", G_CALLBACK (ev_application_window_destroyed), |