[Xfce4-commits] <xfce4-mpc-plugin:master> backout previous in parse_playlistinfo_answer, as we play tricks with fake OKs

Landry Breuil noreply at xfce.org
Sat Oct 16 12:38:03 CEST 2010


Updating branch refs/heads/master
         to 389a8c83f6430af7e13b378bad4f6841fde45462 (commit)
       from a562cabe0cabec9ea478db8ad9c3579afe2146fc (commit)

commit 389a8c83f6430af7e13b378bad4f6841fde45462
Author: Landry Breuil <landry at xfce.org>
Date:   Sat Oct 16 12:29:43 2010 +0200

    backout previous in parse_playlistinfo_answer, as we play tricks with fake OKs

 panel-plugin/simple-libmpd.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/panel-plugin/simple-libmpd.c b/panel-plugin/simple-libmpd.c
index 63e1689..1913308 100644
--- a/panel-plugin/simple-libmpd.c
+++ b/panel-plugin/simple-libmpd.c
@@ -414,7 +414,7 @@ void parse_playlistinfo_answer(MpdObj *mo, void *param)
       ms->id = ms->pos = -1;
       DBG("Going to parse song #%d", md->nb);
 
-      while(lines[i] && strcmp(lines[i],"OK") && ms->id < 0)
+      while(lines[i] && ms->id < 0)
       {
          tokens = g_strsplit(lines[i], ":", 2);
          /* remove leading whitespace */
@@ -430,8 +430,7 @@ void parse_playlistinfo_answer(MpdObj *mo, void *param)
          i++;
          g_strfreev(tokens);
       }
-      if (lines[i] && strcmp(lines[i],"OK"))
-         md->nb++;
+      md->nb++;
    }
    g_strfreev(lines);
    DBG("Got 'OK', md->nb = %d", md->nb);



More information about the Xfce4-commits mailing list