GNOME Bugzilla – Bug 687265
deadlock in libcanberra-pulse with gstreamer 1.0.2
Last modified: 2013-03-04 18:19:09 UTC
using g-s master (3.7.1 eb09f341), i'm getting a deadlock in libcanberra-pulse after changing workspaces a few times. I'm guessing any event triggering a (desktop) sound will do the same. This is confirmed by gdb: (gdb) bt
+ Trace 231118
this is with libcanberra 0.30, pulseaudio 2.1 and gstreamer 1.0.2.
hm, I see workspace_switch_sound() is in mutter, not in g-s. I'm using mutter from master (3.7.1 2cc0d31b) in case it matters. this is a recent regression for me. My libcanberra & pulseaudio didn't change recently, but my gstreamer did (1.0.1 -> 1.0.2), not sure if it's related.
Please file a bug in GStreamer.
> Please file a bug in GStreamer. I don't see anything GStreamer-related in that stack trace though?
indeed. I downgraded gst from 1.0.2 to 1.0.1 and it seemed better for a while, but it didn't last. g-s is still freezing on the same libcanberra deadlock (when switching workspaces with the keyboard shotcuts). I also tried downgrading canberra from 0.30 to 0.29, same thing. I'm starting to suspect glib, I have 2.35.2. Could be something like bug 686810
Created attachment 229179 [details] all threads bt attaching the all threads stacks of my current state (still with glib master) in case it helps.
I see this too in the latest gnome-ostree; as of this writing, git master of glib, gstreamer, libcanberra, gnome-shell, and pulseaudio-2.x branch.
I'm still seeing this g-s freeze many times a day with most of gnome from git master, but strangely, only on my x64 desktop. My 32bit desktop running the exact same git revisions seems immune to this. I noticed rhythmbox is also deadlocking (also x64 only) when i pause/play it, and that's in gst-pulse: (gdb) bt
+ Trace 231213
Downgrading libc6 from 2.16 to 2.13 have done the trick (required a rebuild of the items that I built after the upgrade so not iso but still looks likely the culprit). Was achievable here as I just upgrade libc6 from debian experimental and had done build of only a handful items (not even libcanberra or pulseaudio which were the only items affected in my gnome-shell freeze. For rhtyhmbox I have the same issue if moving the position slider or when the song change. But this time the issue happens in gstreamer pulse plugin). I guess for system already fully transitioned to libc6 2.16 , it would be easier to check on a 2.13 system and then upgrade only libc6 and retry.
This upstream glibc 2.16 bug: http://sourceware.org/bugzilla/show_bug.cgi?id=14417 libcanberra and gstreamer hangs on pulseaudio calls. Upstream fixed this only in master at : http://sourceware.org/git/?p=glibc.git;a=commit;h=c30e8edf7c56e55a81173da39f3e721ab17b9db6 Debian for example had reverted one upstream commit to avoid this issue (there was no upstream fix back then ... but only did for x86 not x86_64). Thus I submitted http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=694962 to them with a conversion of this upstream patch . This works well.
My workaround: gsettings set org.gnome.desktop.sound event-sounds false
Confirmed that backporting http://sourceware.org/git/?p=glibc.git;a=commit;h=c30e8edf7c56e55a81173da39f3e721ab17b9db6 solves it.