After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 654172 - gnome-control-center crashed with SIGSEGV in g_type_instance_get_private() (device_services_changed)
gnome-control-center crashed with SIGSEGV in g_type_instance_get_private() (d...
Status: RESOLVED FIXED
Product: gnome-bluetooth
Classification: Core
Component: general
3.1.x
Other Linux
: Normal critical
: ---
Assigned To: gnome-bluetooth-general-maint@gnome.bugs
gnome-bluetooth-general-maint@gnome.bugs
: 661118 661173 666203 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2011-07-07 16:17 UTC by Pedro Villavicencio
Modified: 2012-01-09 11:00 UTC
See Also:
GNOME target: ---
GNOME version: 3.1/3.2


Attachments
lib: Disconnect signals from adapters and devices on finalize (1.88 KB, patch)
2011-10-11 08:04 UTC, Vincent Untz
committed Details | Review
lib: Do not leak proxies for detectable interfaces of devices (2.18 KB, patch)
2011-10-11 08:04 UTC, Vincent Untz
committed Details | Review

Description Pedro Villavicencio 2011-07-07 16:17:03 UTC
this report has been filed here:

https://bugs.launchpad.net/ubuntu/+source/gnome-bluetooth/+bug/805311

"crashed while trying to manage sound preferences for a bluetooth headset."

gnome-bluetooth version is 3.1.3-0ubuntu1

backtrace:

".

Thread 1 (Thread 19273)

  • #0 g_type_instance_get_private
    at /build/buildd/glib2.0-2.29.8/./gobject/gtype.c line 4503
  • #1 device_services_changed
    at bluetooth-client.c line 374
  • #2 marshal_dbus_message_to_g_marshaller
    at dbus-gproxy.c line 1733
  • #3 g_closure_invoke
    at /build/buildd/glib2.0-2.29.8/./gobject/gclosure.c line 771
  • #4 signal_emit_unlocked_R
    at /build/buildd/glib2.0-2.29.8/./gobject/gsignal.c line 3256
  • #5 g_signal_emit_valist
    at /build/buildd/glib2.0-2.29.8/./gobject/gsignal.c line 2987
  • #6 g_signal_emit
    at /build/buildd/glib2.0-2.29.8/./gobject/gsignal.c line 3044
  • #7 dbus_g_proxy_emit_remote_signal
    at dbus-gproxy.c line 1786
  • #8 dbus_g_proxy_manager_filter
    at dbus-gproxy.c line 1353
  • #9 dbus_g_proxy_manager_filter
    at dbus-gproxy.c line 1194
  • #10 dbus_connection_dispatch
    at dbus-connection.c line 4647
  • #11 message_queue_dispatch
    at dbus-gmain.c line 90
  • #12 g_main_dispatch
    at /build/buildd/glib2.0-2.29.8/./glib/gmain.c line 2477
  • #13 g_main_context_dispatch
    at /build/buildd/glib2.0-2.29.8/./glib/gmain.c line 3050
  • #14 g_main_context_iterate
    at /build/buildd/glib2.0-2.29.8/./glib/gmain.c line 3128
  • #15 g_main_loop_run
    at /build/buildd/glib2.0-2.29.8/./glib/gmain.c line 3336
  • #16 gtk_main
    at /build/buildd/gtk+3.0-3.1.6/./gtk/gtkmain.c line 1363
  • #17 g_application_run
    at /build/buildd/glib2.0-2.29.8/./gio/gapplication.c line 1326
  • #18 main
    at control-center.c line 180

Comment 1 Michael Terry 2011-09-16 19:45:34 UTC
This looks like the device_services_changed signal handler is never disconnected when the client dies.  And looking at the code, that seems to be the case.  Same for the device_changed signal handler.

I believe both should be disconnected in the finalize function like the other signal handlers.
Comment 2 Bastien Nocera 2011-09-16 19:56:41 UTC
That portion of the code is absolutely too fragile because of dbus-glib.
Comment 3 Vincent Untz 2011-10-11 08:04:11 UTC
So I have two patches that seem to fix the crashes for me. The second one is quite horrible, but... well, that's with minimal impact on the code. The real fix is already on master, with the move to gdbus (at least, I hope it doesn't crash there). But for 3.2, we still need something, and that's what I'm going to use.

Note that bug 661118, bug 661172, bug 661173 and bug 661177 are likely all duplicate of this bug.
Comment 4 Vincent Untz 2011-10-11 08:04:20 UTC
Created attachment 198767 [details] [review]
lib: Disconnect signals from adapters and devices on finalize

This avoids some crashes.

https://bugzilla.gnome.org/show_bug.cgi?id=661118
Comment 5 Vincent Untz 2011-10-11 08:04:32 UTC
Created attachment 198768 [details] [review]
lib: Do not leak proxies for detectable interfaces of devices

This avoids signals that will cause crashes.
Comment 6 Bastien Nocera 2011-10-19 14:32:59 UTC
*** Bug 661118 has been marked as a duplicate of this bug. ***
Comment 7 Bastien Nocera 2011-10-19 14:33:11 UTC
*** Bug 661172 has been marked as a duplicate of this bug. ***
Comment 8 Bastien Nocera 2011-10-19 14:33:17 UTC
*** Bug 661173 has been marked as a duplicate of this bug. ***
Comment 9 Bastien Nocera 2011-10-19 14:33:28 UTC
*** Bug 661177 has been marked as a duplicate of this bug. ***
Comment 10 Bastien Nocera 2011-10-19 14:35:03 UTC
Attachment 198767 [details] pushed as 8be8b92 - lib: Disconnect signals from adapters and devices on finalize
Attachment 198768 [details] pushed as f591ab0 - lib: Do not leak proxies for detectable interfaces of devices
Comment 11 Bastien Nocera 2012-01-09 11:00:45 UTC
*** Bug 666203 has been marked as a duplicate of this bug. ***