Comment 48 for bug 486154

Revision history for this message
Grondr (grondr) wrote :

Confirmed---your patch fixes the issue. Now I can migrate to Karmic without going mad. (I'll make a post showing all the extant bugs & what fixes them, since this is but one part of all the bell lossage we've discovered, but this is certainly the most-annoying one and the one that got us started... :)

And I -absolutely- agree that it's PulseAudio's job to be screwing around with the bell! It's documented, it's configurable, and it'll work with -all- PA-capable window managers, rather than metacity being a weird special case. Pity that this bug started out (see title bar, etc) with my guess that it was PA and not metacity; oh well.

Strictly speaking, I don't think you need part 3 of your patch---I tried tests using the various pieces of it in isolation, and it looks like the bell will be audible even if the #ifdef is replaced by HAVE_XKB_NOPE or some other thing that keeps it commented-out. However, it can't hurt, and it may allow metacity to counteract similar lossage by some other window manager leaving us in a bad state. (Btw, I also made sure that sudo metacity while ssh'ed in from another host no longer stole -its- bell, either.)

I'm pretty sure my testing commented out the line in #4, but I can't remember if I also tried diddling the mask correctly instead. Given that every time gdm gets restarted, the X bell volume is set to zero, it's also possible I had it right at some point but never knew it---if I'd forgotten to do xset b.

And yes, your #2 is necessary---otherwise, you get the motherboard beep -and- bell.ogg played simultaneously (but the beep is not rate-limited, whereas bell.ogg is). [Or, if you haven't loaded pcspkr yet, you get a squarewave beep out the line-out port, along with bell.ogg). I note also that bell.ogg is still delayed, especially the first one after a long silence.

I haven't tried out all the various weirdo permutations I did in my comment #34 (bug-characterization), but since the normal-boot-into-gdm-and-metacity case now works, I'd be very surprised if anything else was broken---things are now working like my pre-9.XX control case.

Also, it looks like the "vanishing bell" problem has itself vanished; this was result (d) in my characterization (e.g., "beep" with 10-second delays would tend to emit a beep every -20- seconds). Looks like metacity was responsible for -that- bit of lossage, too.

Yay!

I suspect somebody should open a bug upstream, directly at metacity's bugtracker, and point them at your patch (and at this entire thread, as motivation for just what a PITA this bit of metacity behavior has been). I'm going to post a step-by-step about how to configure all the moving parts to get bells back as my next post, so somebody searching for it might win (since even with the patch, there's a lot of other stuff that has to get set correctly).