------------------------------------------------------------------------ r10971 | duncan | 2008-08-27 20:45:30 +0200 (Wed, 27 Aug 2008) | 2 lines Fixed a bug where remove didn't do what was expected; need to use filter instead ------------------------------------------------------------------------ Index: freevo/src/audio/plugins/mplayervis2.py =================================================================== --- freevo/src/audio/plugins/mplayervis2.py (revision 10970) +++ freevo/src/audio/plugins/mplayervis2.py (revision 10971) @@ -511,7 +511,7 @@ args['verbose'] = '-v' vo = ['%(vo)s' % args, '%(vo_opts)s' % args] - vo.remove('') + vo = filter(len, vo) vo = ':'.join(vo) command = ['%(cmd)s' % args] @@ -531,8 +531,7 @@ elif '-framedrop' not in command: command += config.MPLAYER_SOFTWARE_SCALER.split() - while '' in command: - command.remove('') + command = filter(len, command) command += ['%(url)s' % args] Index: freevo/src/video/plugins/mplayer.py =================================================================== --- freevo/src/video/plugins/mplayer.py (revision 10970) +++ freevo/src/video/plugins/mplayer.py (revision 10971) @@ -299,11 +299,11 @@ command = p.play(command, self) vo = ['%(vo)s' % args, '%(vo_opts)s' % args] - vo.remove('') + vo = filter(len, vo) vo = ':'.join(vo) ao = ['%(ao)s' % args, '%(ao_opts)s' % args] - ao.remove('') + ao = filter(len, ao) ao = ':'.join(ao) command = ['--prio=%(nice)s' % args] @@ -342,8 +342,7 @@ if options: command += options - while '' in command: - command.remove('') + command = filter(len, command) command = self.sort_filter(command) Index: freevo/src/tv/plugins/mplayer.py =================================================================== --- freevo/src/tv/plugins/mplayer.py (revision 10970) +++ freevo/src/tv/plugins/mplayer.py (revision 10971) @@ -192,11 +192,11 @@ _debug_('mplayer args = %r' % (args,)) vo = ['%(vo)s' % args, '%(vo_opts)s' % args] - vo.remove('') + vo = filter(len, vo) vo = ':'.join(vo) ao = ['%(ao)s' % args, '%(ao_opts)s' % args] - ao.remove('') + ao = filter(len, ao) ao = ':'.join(ao) command = ['--prio=%(nice)s' % args] @@ -235,8 +235,7 @@ #if options: # command += options - while '' in command: - command.remove('') + command = filter(len, command) #command = self.sort_filter(command) Index: freevo/src/childapp.py =================================================================== --- freevo/src/childapp.py (revision 10970) +++ freevo/src/childapp.py (revision 10971) @@ -87,8 +87,7 @@ debug_name = app[:app.find(' ')] else: - while '' in app: - app.remove('') + app = filter(len, app) if app[0].find('--prio=') == 0 and not config.RUNAPP: try: