]> rtime.felk.cvut.cz Git - sojka/lightdm.git/commitdiff
Only delete socket if we're about to use it
authorMichael Terry <michael.terry@canonical.com>
Wed, 30 Apr 2014 18:37:27 +0000 (14:37 -0400)
committerMichael Terry <michael.terry@canonical.com>
Wed, 30 Apr 2014 18:37:27 +0000 (14:37 -0400)
debian/lightdm.upstart
src/unity-system-compositor.c

index 663f9eadf648db7d5cfa5a5834cde4844e36fb2c..9395ad5656a1eccdd61d260ae5d629bfd2b02009 100644 (file)
@@ -45,7 +45,6 @@ script
        fi
     fi
 
-    rm -f /tmp/mir_socket
     exec lightdm
 end script
 
index 7ba95e4289708e00bf1de0c57b94c1b93a5cad9d..ed31a394d925c4a383c22a1d69262614e15cb49f 100644 (file)
@@ -417,6 +417,9 @@ unity_system_compositor_start (DisplayServer *server)
         process_set_env (compositor->priv->process, "LD_LIBRARY_PATH", g_getenv ("LD_LIBRARY_PATH"));
     }
 
+    /* Delete a potential stale socket before USC tries to use it */
+    g_unlink (compositor->priv->socket);
+
     /* Generate command line to run */
     absolute_command = get_absolute_command (compositor->priv->command);
     if (!absolute_command)