1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-21 13:10:33 +00:00
nixpkgs/pkgs/development/libraries/consolekit/0002-Don-t-take-bus-name-until-ready.patch
Eelco Dolstra 94e6e50a58 * Revert ConsoleKit to 0.4.1 because newer versions break device
ownership assignment with the SLIM display manager.  (The workaround
  in r28400 doesn't work on i686-linux.)

  A better solution would be for SLIM to have proper ConsoleKit
  support, but it seems unmaintained.  We should probably ditch it for
  something like LightDM.

svn path=/nixpkgs/trunk/; revision=28586
2011-08-15 14:47:18 +00:00

63 lines
1.6 KiB
Diff

Upstream patch
From 2418840248f07025ad0edc96ed17e03ce5e47f3e Mon Sep 17 00:00:00 2001
From: Ray Strode <rstrode@redhat.com>
Date: Mon, 21 Dec 2009 11:14:54 -0500
Subject: [PATCH 2/2] Don't take bus name until ready
Previously, we would take a bus name right away, but
not register the manager object until later. This
causes a race when being activated by a method call
on the manager object, where ConsoleKit gets started
but the method call fails.
https://bugs.freedesktop.org/show_bug.cgi?id=25744
---
src/main.c | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/src/main.c b/src/main.c
index 809c6d6..b8f698f 100644
--- a/src/main.c
+++ b/src/main.c
@@ -294,11 +294,19 @@ main (int argc,
setup_debug_log (debug);
+ g_debug ("initializing console-kit-daemon %s", VERSION);
+
connection = get_system_bus ();
if (connection == NULL) {
goto out;
}
+ manager = ck_manager_new ();
+
+ if (manager == NULL) {
+ goto out;
+ }
+
bus_proxy = get_bus_proxy (connection);
if (bus_proxy == NULL) {
g_warning ("Could not construct bus_proxy object; bailing out");
@@ -310,16 +318,8 @@ main (int argc,
goto out;
}
- g_debug ("initializing console-kit-daemon %s", VERSION);
-
create_pid_file ();
- manager = ck_manager_new ();
-
- if (manager == NULL) {
- goto out;
- }
-
loop = g_main_loop_new (NULL, FALSE);
g_signal_connect (bus_proxy,
--
1.7.1