GNOME Bugzilla – Bug 130788
crashes when using song position slider
Last modified: 2009-08-15 18:40:50 UTC
Rhythmbox crashes when I use the slider for the song position very intensely. Steps to reproduce the crash: 1. start rhythmbox with a larger song collection (>3 GB) and start playing 2. click fast several times in the song slider to slide forward 3. or pick the slider with the mouse, slide forward, let go and repeat this immediatly 4. or do something like slide, click, slide, click, ... Expected Results: rhythmbox freezes How often does this happen? everytime Additional Information: Sometimes this behaviour only occurs afte playing for a while (> half an hour).
I have found *a* bug in the way that slider movement is handled. I do not know if it is *the* bug causing this particular problem, but the expected impact is at least consistent with what has been described here. When the user repositions the slider widget, Rhythmbox doesn't change its playback position immediately. Rather, this is deferred using a brief timeout. However, the slider widget keeps around this timeout's event source ID even after the timeout object itself has already been destroyed. Later on, this dangling ID can fool the code into mistakenly destroying some other event source at random. The bad code pattern here is identical to that recently reported for a timeout used to animate the browser disclosure widget. In the later case, destroying an event source using the dangling event ID is known to be associated with subsequent crashes. This has been reported as bug #137460. I don't have test data that includes slder interaction, but it's certainly quite possble that the slider's dangling event ID is also causing crashes here. I will attach a proposed (but untested) fix shortly.
Created attachment 25715 [details] [review] proposed fix: zero out ID after one-shot timeout has fired
The patch attached above is against Rhythmbox 0.6.5. It appears that the source file to be patched has been renamed in subsequent versions. I believe the code currently lives in "widgets/rb-header.c". The problem remains as described, though, and the one-line fix should be easy to locate and apply by hand if necessary.
Cool, thanks again for the description and the patch. * committed rhythmbox-devel@gnome.org--2004/rhythmbox--main--0.7--patch-154 By the way, if you used arch, you could submit changesets that would work even when files were renamed :) http://web.rhythmbox.org/development.html
I couldn't reproduce the bug anymore, so I guess it is fixed now. :) Great work.
Thanks for following up.