1 From c2e317911f2fae424ec9a121f267e4a83efcf1c5 Mon Sep 17 00:00:00 2001
2 From: Halton Huo <halton.huo@sun.com>
3 Date: Wed, 19 May 2010 12:46:25 +0800
4 Subject: [PATCH] Enhancement CanActivateSessions for OpenSolaris.
6 VT switching is always enabled on Linux, but for OpenSolaris VT switching
7 can be truned of by 'svcadm disable vtdaemon'. So we should also check
8 whether the service vtdaemon is online on OpenSolaris.
10 https://bugs.freedesktop.org/show_bug.cgi?id=26055
13 src/ck-sysdeps-freebsd.c | 6 ++++++
14 src/ck-sysdeps-linux.c | 6 ++++++
15 src/ck-sysdeps-solaris.c | 18 ++++++++++++++++++
16 src/ck-sysdeps.h | 1 +
17 5 files changed, 32 insertions(+), 0 deletions(-)
19 diff --git a/src/ck-sysdeps-linux.c b/src/ck-sysdeps-linux.c
20 index 09db310..a95272e 100644
21 --- a/src/ck-sysdeps-linux.c
22 +++ b/src/ck-sysdeps-linux.c
23 @@ -693,6 +693,12 @@ ck_get_max_num_consoles (guint *num)
28 +ck_supports_activatable_consoles (void)
34 ck_get_console_device_for_num (guint num)
36 --- ConsoleKit-0.4.1/src/ck-seat.c-orig 2011-02-07 22:09:46.085393510 -0600
37 +++ ConsoleKit-0.4.1/src/ck-seat.c 2011-02-07 22:10:58.766029875 -0600
38 @@ -1172,6 +1172,10 @@ ck_seat_can_activate_sessions (CkSeat
40 g_return_val_if_fail (CK_IS_SEAT (seat), FALSE);
42 + if (ck_supports_activatable_consoles () == FALSE) {
46 if (can_activate != NULL) {
47 *can_activate = (seat->priv->kind == CK_SEAT_KIND_STATIC);