diff options
author | Havoc Pennington <hp@redhat.com> | 2003-04-25 20:41:49 +0000 |
---|---|---|
committer | Havoc Pennington <hp@redhat.com> | 2003-04-25 20:41:49 +0000 |
commit | 9c010fbc04a450cc13484682abfbecd31f610305 (patch) | |
tree | b6f8b0cd5b67dbf3b9772956959d616397097ad9 /glib | |
parent | 3185d7edde8ffc7672aa7d771966b0f1e0158aea (diff) |
2003-04-25 Havoc Pennington <hp@redhat.com>
* glib/dbus-gmain.c (remove_watch): fix for a crash when watches
were toggled without add/remove, fix from Anders Gustafsson
Diffstat (limited to 'glib')
-rw-r--r-- | glib/dbus-gmain.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/glib/dbus-gmain.c b/glib/dbus-gmain.c index 15490fbd..dd9ea375 100644 --- a/glib/dbus-gmain.c +++ b/glib/dbus-gmain.c @@ -275,6 +275,10 @@ remove_watch (DBusWatch *watch, dbus_source->poll_fds = g_list_remove (dbus_source->poll_fds, poll_fd); g_hash_table_remove (dbus_source->watches, poll_fd); g_source_remove_poll ((GSource *)dbus_source, poll_fd); + + dbus_watch_set_data (watch, NULL, NULL); /* needed due to watch_toggled + * breaking add/remove symmetry + */ g_free (poll_fd); } |