Activity log for bug #1732850

Date Who What changed Old value New value Message
2017-11-17 06:34:05 Joel Barrios bug added bug
2017-11-17 06:34:05 Joel Barrios attachment added lightdm-1.24.0-fix-consolekit2-support.patch https://bugs.launchpad.net/bugs/1732850/+attachment/5010339/+files/lightdm-1.24.0-fix-consolekit2-support.patch
2017-11-17 06:39:41 Joel Barrios summary Wrong variant in CanSusoend and CanHibernate in ConsoleKit2 support. Wrong variant in CanSuspend and CanHibernate in ConsoleKit2 support.
2017-11-17 06:57:57 Joel Barrios description Systems using ConsoleKit2 instead of SystemD o elogind cannot suspend or hibernate from LightDM 1.24.0. According to ConsoleKit2 documentation: ... CanSuspend (out 's' can_suspend) ... CanHibernate (out 's' can_hibernate) ... But the code in liblightdm-gobject/power.c uses 'b': r = ck_call_function ("CanSuspend", NULL, NULL); if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(b)"))) g_variant_get (r, "(b)", &can_suspend); r = ck_call_function ("CanHibernate", NULL, NULL); if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(b)"))) g_variant_get (r, "(b)", &can_hibernate); After changing "(b)" with "(s)", LightDM 1.24.0 can suspend an hibernate again in systems with ConsoleKit2. r = ck_call_function ("CanSuspend", NULL, NULL); if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(s)"))) g_variant_get (r, "(s)", &can_suspend); r = ck_call_function ("CanHibernate", NULL, NULL); if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(s)"))) g_variant_get (r, "(s)", &can_hibernate); Systems using ConsoleKit2 instead of SystemD or elogind cannot suspend or hibernate from LightDM 1.24.0. According to ConsoleKit2 documentation: ... CanSuspend (out 's' can_suspend) ... CanHibernate (out 's' can_hibernate) ... But the code in liblightdm-gobject/power.c uses 'b':         r = ck_call_function ("CanSuspend", NULL, NULL);         if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(b)")))             g_variant_get (r, "(b)", &can_suspend);        r = ck_call_function ("CanHibernate", NULL, NULL);         if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(b)")))             g_variant_get (r, "(b)", &can_hibernate); After changing "(b)" with "(s)", LightDM 1.24.0 can suspend an hibernate again in systems with ConsoleKit2.         r = ck_call_function ("CanSuspend", NULL, NULL);         if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(s)")))             g_variant_get (r, "(s)", &can_suspend);        r = ck_call_function ("CanHibernate", NULL, NULL);         if (r && g_variant_is_of_type (r, G_VARIANT_TYPE ("(s)")))             g_variant_get (r, "(s)", &can_hibernate);
2018-01-22 23:32:56 Robert Ancell lightdm: status New Triaged
2018-01-22 23:32:58 Robert Ancell lightdm: importance Undecided High
2018-01-22 23:35:26 Robert Ancell lightdm: status Triaged Fix Committed