diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /lxde-base/lxsession/files/lxsession-0.4.9.2-fix-logind-dbus-calls.patch | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'lxde-base/lxsession/files/lxsession-0.4.9.2-fix-logind-dbus-calls.patch')
-rw-r--r-- | lxde-base/lxsession/files/lxsession-0.4.9.2-fix-logind-dbus-calls.patch | 111 |
1 files changed, 111 insertions, 0 deletions
diff --git a/lxde-base/lxsession/files/lxsession-0.4.9.2-fix-logind-dbus-calls.patch b/lxde-base/lxsession/files/lxsession-0.4.9.2-fix-logind-dbus-calls.patch new file mode 100644 index 000000000000..91d15836241a --- /dev/null +++ b/lxde-base/lxsession/files/lxsession-0.4.9.2-fix-logind-dbus-calls.patch @@ -0,0 +1,111 @@ +Taken from: +http://svnweb.mageia.org/packages/cauldron/lxsession/current/SOURCES/lxsession-0.4.9.2-fix-logind-dbus-calls.patch?revision=549605&view=co&pathrev=549606 + +--- lxsession-0.4.9.2/lxsession-logout/dbus-interface.c.0000 2013-04-12 22:02:19.000000000 +0100 ++++ lxsession-0.4.9.2/lxsession-logout/dbus-interface.c 2013-11-05 11:00:34.038965063 +0000 +@@ -244,10 +244,11 @@ + return function_result; + } + +-static void +-logind_call_function (const gchar *function, gboolean value, GError **error) ++static char * ++logind_call_function (const gchar *function) + { + GVariant *result; ++ GError *err = NULL; + + if (!logind_proxy) + { +@@ -258,20 +259,28 @@ + "/org/freedesktop/login1", + "org.freedesktop.login1.Manager", + NULL, +- error); ++ &err); ++ if (err != NULL) ++ g_error_free(err); + if (!logind_proxy) +- return; ++ return NULL; + } + + result = g_dbus_proxy_call_sync (logind_proxy, + function, +- g_variant_new ("(b)", value), ++ g_variant_new ("(b)", TRUE), + G_DBUS_CALL_FLAGS_NONE, + -1, + NULL, +- error); +- g_variant_unref (result); +- return; ++ &err); ++ if (result) ++ g_variant_unref (result); ++ if (err != NULL) { ++ char *r = strdup(err->message); ++ g_error_free(err); ++ return r; ++ } ++ return NULL; + } + + gboolean +@@ -280,10 +289,10 @@ + return logind_query ("CanPowerOff", FALSE, NULL); + } + +-void +-dbus_logind_PowerOff (GError **error) ++char * ++dbus_logind_PowerOff (void) + { +- logind_call_function ("PowerOff", TRUE, error); ++ return logind_call_function ("PowerOff"); + } + + gboolean +@@ -292,10 +301,10 @@ + return logind_query ("CanReboot", FALSE, NULL); + } + +-void +-dbus_logind_Reboot (GError **error) ++char * ++dbus_logind_Reboot (void) + { +- logind_call_function ("Reboot", TRUE, error); ++ return logind_call_function ("Reboot"); + } + + gboolean +@@ -304,10 +313,10 @@ + return logind_query ("CanSuspend", FALSE, NULL); + } + +-void +-dbus_logind_Suspend (GError **error) ++char * ++dbus_logind_Suspend (void) + { +- logind_call_function ("Suspend", TRUE, error); ++ return logind_call_function ("Suspend"); + } + + gboolean +@@ -316,10 +325,10 @@ + return logind_query ("CanHibernate", FALSE, NULL); + } + +-void +-dbus_logind_Hibernate (GError **error) ++char * ++dbus_logind_Hibernate (void) + { +- logind_call_function ("Hibernate", TRUE, error); ++ return logind_call_function ("Hibernate"); + } + + /*** ConsoleKit mechanism ***/ + |