[Goodies-commits] r4120 - xfmpc/trunk/src
Mike Massonnet
mmassonnet at xfce.org
Fri Mar 28 01:50:03 CET 2008
Author: mmassonnet
Date: 2008-03-28 00:50:03 +0000 (Fri, 28 Mar 2008)
New Revision: 4120
Modified:
xfmpc/trunk/src/mpdclient.c
Log:
Fix bug in playlist when there is no current song
* mpdclient.c(xfmpc_mpdclient_get_pos):
- Return 0 if pos is < 0
Modified: xfmpc/trunk/src/mpdclient.c
===================================================================
--- xfmpc/trunk/src/mpdclient.c 2008-03-28 00:49:58 UTC (rev 4119)
+++ xfmpc/trunk/src/mpdclient.c 2008-03-28 00:50:03 UTC (rev 4120)
@@ -399,7 +399,11 @@
{
XfmpcMpdclientPrivate *priv = XFMPC_MPDCLIENT_GET_PRIVATE (mpdclient);
- return mpd_player_get_current_song_pos (priv->mi);
+ gint pos = mpd_player_get_current_song_pos (priv->mi);
+ if (pos < 0)
+ pos = 0;
+
+ return pos;
}
gint
More information about the Goodies-commits
mailing list