mate-desktop / mate-media

Media tools for MATE
https://mate-desktop.org
GNU General Public License v2.0
19 stars 25 forks source link

mate-media: g_free_sized(): mate-volume-control-applet killed by SIGABRT #200

Closed raveit65 closed 1 year ago

raveit65 commented 1 year ago

This is one of repeating bugs which occurred very often in fedora in the last years and were reported by users via fedora bug reporting tool. Mostly mate-media and mate-settings-daemon crashes together, because they are connected via libmatemixer, pulseaudio, etc. Related m-s-d issue: https://github.com/mate-desktop/mate-settings-daemon/issues/401 This is a blocker bug which prevent me to switch the applet to in-process build to avoid that the whole panel crashes. No in-process --> no wayland session.

Actual behaviour

Truncated backtrace:
Thread no. 1 (29 frames)
 #8 g_free_sized at ../glib/gmem.c:258
 #9 g_slice_free1 at ../glib/gslice.c:336
 #10 handler_unref_R.part.0.lto_priv.0 at ../gobject/gsignal.c:773
 #11 handler_unref_R at ../gobject/gsignal.c:728
 #12 handler_match_free1_R at ../gobject/gsignal.c:595
 #13 signal_handlers_foreach_matched_unlocked_R at ../gobject/gsignal.c:2931
 #14 g_signal_handlers_disconnect_matched at ../gobject/gsignal.c:3084
 #15 gvc_channel_bar_set_control at /usr/src/debug/mate-media-1.26.1-1.fc38.x86_64/mate-volume-control/gvc-channel-bar.c:584
 #17 gvc_stream_applet_icon_set_control at /usr/src/debug/mate-media-1.26.1-1.fc38.x86_64/mate-volume-control/gvc-stream-applet-icon.c:550
 #18 update_icon_output at /usr/src/debug/mate-media-1.26.1-1.fc38.x86_64/mate-volume-control/gvc-applet.c:161
 #20 signal_emit_unlocked_R.isra.0 at ../gobject/gsignal.c:3812
 #24 g_object_notify_by_spec_internal at ../gobject/gobject.c:1552
 #25 g_object_notify_by_pspec at ../gobject/gobject.c:1658
 #27 signal_emit_unlocked_R.isra.0 at ../gobject/gsignal.c:3812
 #31 g_object_notify_by_spec_internal at ../gobject/gobject.c:1552
 #32 g_object_notify_by_pspec at ../gobject/gobject.c:1658
 #33 _mate_mixer_backend_set_default_output_stream at /usr/src/debug/libmatemixer-1.26.0-4.fc38.x86_64/libmatemixer/matemixer-backend.c:654
 #34 on_connection_sink_removed at /usr/src/debug/libmatemixer-1.26.0-4.fc38.x86_64/backends/pulse/pulse-backend.c:869
 #36 signal_emit_unlocked_R.isra.0 at ../gobject/gsignal.c:3812
 #39 pa_command_subscribe_event at ../src/pulse/subscribe.c:53
 #40 pa_pdispatch_run at ../src/pulsecore/pdispatch.c:349
 #41 pstream_packet_callback at ../src/pulse/context.c:364
 #42 do_read at ../src/pulsecore/pstream.c:1023
 #43 do_pstream_read_write at ../src/pulsecore/pstream.c:261
 #44 dispatch_func at ../src/pulse/glib-mainloop.c:581
 #47 g_main_context_iterate.isra.0 at ../glib/gmain.c:4276
 #49 gtk_main at ../gtk/gtkmain.c:1329
 #50 _mate_panel_applet_factory_main_internal at /usr/src/debug/mate-panel-1.26.3-1.fc38.x86_64/libmate-panel-applet/mate-panel-applet.c:2459
 #51 mate_panel_applet_factory_main at /usr/src/debug/mate-panel-1.26.3-1.fc38.x86_64/libmate-panel-applet/mate-panel-applet.c:2487

Full backtrace at https://bugzilla.redhat.com/attachment.cgi?id=1976340

Steps to reproduce the behaviour

User info: This is one of those that I am not sure why it happened. It is related to media, so maybe it was turning off a bluetooth headset that "caused it" but can't be sure. occurs with https://bugzilla.redhat.com/show_bug.cgi?id=2223656

MATE general version

1.26.x

Package version

mate-media-1.26.1

Linux Distribution

fedora 38

Link to bugreport of your Distribution (requirement)

https://bugzilla.redhat.com/show_bug.cgi?id=2223657

raveit65 commented 1 year ago

@mate-desktop/core-team

lukefromdc commented 1 year ago

We have on_connection_sink_removed at /usr/src/debug/libmatemixer-1.26.0-4.fc38.x86_64/backends/pulse/pulse-backend. in the backtrace, suggesting turning off that Bluetooth headset was indeed the trigger. Note that unlike another of these, this backtrace does not mention tooltips so we have multiple issues going on.\

In this backtrace, the topmost piece of our code is gvc_channel_bar_set_control So probably when the bluetooth headset is turned off bad data is getting sent there. This could actually be bad data coming from libmatemixer if so. Either that would have to be fixed or checks added to mate-media and mate-settings-daemon's sound plugin to not attempt to use this bad data with any widget.

lukefromdc commented 1 year ago

See https://github.com/mate-desktop/libmatemixer/issues/39

raveit65 commented 1 year ago

https://github.com/mate-desktop/libmatemixer/commit/e9995a70b1ff951cca3471894db2c289d9b0e4f9 is merged.