changeset 345:ce140fff14c7

Off by one caused infinite looping in searching for next sub-tune to play, fixed.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 23 Sep 2005 10:33:04 +0000
parents a0fe42c5b6f4
children 5fe452765b8b
files src/xmms-sid.c
diffstat 1 files changed, 1 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/xmms-sid.c	Fri Sep 23 09:34:02 2005 +0000
+++ b/src/xmms-sid.c	Fri Sep 23 10:33:04 2005 +0000
@@ -366,7 +366,7 @@
  		XSDEBUG("tune #%i already played, finding next match ...\n", myStatus.currSong);
  		isFound = FALSE;
  		i = 0;
- 		while (!isFound && (i <= myTune->nsubTunes))
+ 		while (!isFound && (++i <= myTune->nsubTunes))
  			{
  			if (xs_cfg.subAutoMinOnly)
  				{
@@ -378,9 +378,6 @@
  				if (!playedTune[i])
  					isFound = TRUE;
  				}
-			
-			/* currSong = i + 1 anyway, so we get it free here */
-			i++;
  			}
 
 		if (isFound)