[MPlayer-users] Bug with pls playlist parsing

Kevin DeKorte kdekorte at gmail.com
Mon Jun 13 22:03:34 CEST 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 06/13/2011 01:32 PM, Reimar Döffinger wrote:
> On Mon, Jun 13, 2011 at 12:03:40PM -0600, Kevin DeKorte wrote:
>> The attached playlist will only play the first item in the playlist
>> forever. Based on some investigation into the mplayer code I believe it
>> is due to the code reading the length value of the first item in the
>> playlist, but not using it. I could not figure out how to pass this
>> length so that mplayer would use it.
> 
> I think you're looking for play_tree_set_param

Right, but I was unsure of what arguments to pass to it. I was not sure
what the name should be, "endpos" or some other value.

Anyway, I tried this patch and it seems to fix it.

	
 svn diff
Index: playtreeparser.c
===================================================================
- --- playtreeparser.c	(revision 33606)
+++ playtreeparser.c	(working copy)
@@ -348,6 +348,10 @@
       mp_msg(MSGT_PLAYTREE,MSGL_DBG2,"Adding entry
%s\n",entries[num].file);
       entry = play_tree_new();
       play_tree_add_file(entry,entries[num].file);
+      if (atoi(entries[num].length) > 0) {
+	mp_msg(MSGT_PLAYTREE, MSGL_V, "setting endpos to %s\n",
entries[num].length);
+        play_tree_set_param(entry,"endpos", entries[num].length);
+      }
       free(entries[num].file);
       if(list)
 	play_tree_append_entry(last_entry,entry);

- -- 
Get my public GnuPG key from
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x7D0BD5D1
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAk32bRYACgkQ6w2kMH0L1dFP0QCglfGpxguowuYhR3YF60o3ccNi
rwMAnjI2PRkZy6OkpjyuC+i9KSQdPBwA
=x3Dx
-----END PGP SIGNATURE-----


More information about the MPlayer-users mailing list