Package: moosic Version: 1.5.4-6 Severity: normal Tags: upstream patch
Moosic wipe sometimes replays the currently-playing song when in loop mode. Attached patch has some more commentary. -- System Information: Debian Release: 6.0.1 APT prefers stable APT policy: (500, 'stable') Architecture: i386 (i686) Kernel: Linux 2.6.32-5-686-bigmem (SMP w/2 CPU cores) Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8) (ignored: LC_ALL set to en_US.UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages moosic depends on: ii python 2.6.6-3+squeeze6 interactive high-level object-orie ii python-support 1.0.10 automated rebuilding support for P Versions of packages moosic recommends: ii mpg321 0.2.12-1 Simple and lighweight command line Versions of packages moosic suggests: pn mikmod <none> (no description available) pn sox <none> (no description available) pn timidity <none> (no description available) pn vorbis-tools <none> (no description available) -- no debconf information
--- a/moosic/client/cli/dispatcher.py +++ b/moosic/client/cli/dispatcher.py @@ -578,10 +578,21 @@ if moosic.is_queue_running(): moosic.halt_queue() was_running = True - # skip() must be called before clear() to produce correct behavior while in - # loop mode. Otherwise, the current song would not get removed from the - # queue. - moosic.skip() + + # Previous code used moosic.skip() instead of moosic.stop() in + # the next line. But this sets up a race condition. My best + # guess is that when moosic.skip() kills the player, the player + # does not necessarily die right away (the OS has to get around + # to actually delivering the signal). But, when the player does + # die and moosic is in loop mode, the item being played then + # will go to the end of the playlist because moosic will + # automatically do this when the player dies (even if it was + # killed.) By the time the player has died, moosic.clear() might + # have already run, then the song plays again. moosic.stop() + # seems to avoid this problem because it uses + # data.ignore_song_finish. + + moosic.stop() moosic.clear() if was_running: moosic.run_queue()