[network-manager-applet] editor: add a missing session bus check



commit 6f0941ef26ae1ddf1403c5728b5840603b0d165e
Author: Lubomir Rintel <lkundrak v3 sk>
Date:   Thu Dec 22 15:34:49 2016 +0100

    editor: add a missing session bus check
    
    Only attempt to create an shared application instance only if there actuall is
    a bus that would allow its reuse.

 src/connection-editor/main.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/connection-editor/main.c b/src/connection-editor/main.c
index d848668..b4eac54 100644
--- a/src/connection-editor/main.c
+++ b/src/connection-editor/main.c
@@ -373,7 +373,8 @@ main (int argc, char *argv[])
        }
        g_signal_connect_swapped (list, "done", G_CALLBACK (g_main_loop_quit), loop);
 
-       owner_id = start_service (bus, list, &registration_id);
+       if (bus)
+               owner_id = start_service (bus, list, &registration_id);
 
        /* Figure out what page or editor window we'll show initially */
        if (handle_arguments (list, type, create, show, uuid, import, (create || show || uuid || import)))


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]