* [gentoo-commits] gentoo-x86 commit in gnome-extra/gnome-screensaver/files: gnome-screensaver-2.26.1-remove-inhibitors.patch
@ 2010-01-16 21:54 Pacho Ramos (pacho)
0 siblings, 0 replies; 2+ messages in thread
From: Pacho Ramos (pacho) @ 2010-01-16 21:54 UTC (permalink / raw
To: gentoo-commits
pacho 10/01/16 21:54:12
Added: gnome-screensaver-2.26.1-remove-inhibitors.patch
Log:
Upstream patch for fixing upstream bug 577133
(Portage version: 2.1.7.16/cvs/Linux x86_64)
Revision Changes Path
1.1 gnome-extra/gnome-screensaver/files/gnome-screensaver-2.26.1-remove-inhibitors.patch
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/gnome-extra/gnome-screensaver/files/gnome-screensaver-2.26.1-remove-inhibitors.patch?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/gnome-extra/gnome-screensaver/files/gnome-screensaver-2.26.1-remove-inhibitors.patch?rev=1.1&content-type=text/plain
Index: gnome-screensaver-2.26.1-remove-inhibitors.patch
===================================================================
From 284c9924969a49dbf2d5fae1d680d3310c4df4a3 Mon Sep 17 00:00:00 2001
From: Matthias Clasen <mclasen@redhat.com>
Date: Mon, 02 Nov 2009 23:15:13 +0000
Subject: Remove session inhibitors if the originator falls of the bus
This fixes a problem where totem leaves inhibitors behind, see
bug 600488.
---
diff --git a/src/gs-listener-dbus.c b/src/gs-listener-dbus.c
index e7690a5..7bd3a62 100644
--- a/src/gs-listener-dbus.c
+++ b/src/gs-listener-dbus.c
@@ -986,47 +986,40 @@ listener_dbus_remove_ref_entry (GSListener *listener,
}
static gboolean
-listener_ref_entry_has_connection (gpointer key,
- gpointer value,
- gpointer user_data)
-{
- GSListenerRefEntry *entry;
- const char *connection;
- gboolean matches;
-
- entry = (GSListenerRefEntry *)value;
- connection = (const char *) user_data;
-
- matches = FALSE;
- if (connection != NULL && entry->connection != NULL) {
- matches = (strcmp (connection, entry->connection) == 0);
- if (matches) {
- gs_debug ("removing %s from %s for reason '%s' on connection %s",
- get_name_for_entry_type (entry->entry_type),
- entry->application,
- entry->reason,
- entry->connection);
- }
- }
-
- return matches;
-}
-
-static gboolean
listener_ref_entry_remove_for_connection (GSListener *listener,
int entry_type,
const char *connection)
{
gboolean removed;
- guint n_removed;
GHashTable *hash;
+ GHashTableIter iter;
+ GSListenerRefEntry *entry;
+
+ if (connection == NULL)
+ return FALSE;
hash = get_hash_for_entry_type (listener, entry_type);
removed = FALSE;
- n_removed = g_hash_table_foreach_remove (hash, listener_ref_entry_has_connection, (gpointer)connection);
+ g_hash_table_iter_init (&iter, hash);
+ while (g_hash_table_iter_next (&iter, NULL, (gpointer *)&entry)) {
+ if (entry->connection != NULL &&
+ strcmp (connection, entry->connection) == 0) {
+ gs_debug ("removing %s from %s for reason '%s' on connection %s",
+ get_name_for_entry_type (entry->entry_type),
+ entry->application,
+ entry->reason,
+ entry->connection);
+
+ if (entry->entry_type == REF_ENTRY_TYPE_INHIBIT) {
+ /* remove inhibit from gnome session */
+ remove_session_inhibit (listener, entry);
+ }
- removed = (n_removed > 0);
+ g_hash_table_iter_remove (&iter);
+ removed = TRUE;
+ }
+ }
return removed;
}
--
cgit v0.8.3.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] gentoo-x86 commit in gnome-extra/gnome-screensaver/files: gnome-screensaver-2.26.1-remove-inhibitors.patch
@ 2010-11-23 17:32 Gilles Dartiguelongue (eva)
0 siblings, 0 replies; 2+ messages in thread
From: Gilles Dartiguelongue (eva) @ 2010-11-23 17:32 UTC (permalink / raw
To: gentoo-commits
eva 10/11/23 17:32:53
Removed: gnome-screensaver-2.26.1-remove-inhibitors.patch
Log:
Clean up old revisions.
(Portage version: 2.2.0_alpha4/cvs/Linux x86_64)
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-11-23 17:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-23 17:32 [gentoo-commits] gentoo-x86 commit in gnome-extra/gnome-screensaver/files: gnome-screensaver-2.26.1-remove-inhibitors.patch Gilles Dartiguelongue (eva)
-- strict thread matches above, loose matches on Subject: below --
2010-01-16 21:54 Pacho Ramos (pacho)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox