Bugzilla – Bug 17933
Slim::Formats::Playlists::M3U::read fails with relative paths
Last modified: 2014-01-28 08:37:54 UTC
When scanning a simple m3u file only the odd entries are placed in the playlist within sbs, and they are listed twice, the even entries in the file are ignored. This appears to be an issue when relative file paths are used within the playlist. During the first pass through the loop a relative path stored in $trackurl will be invalid, so the if at 139 will fail, sending it into the else where different combinations of paths are tried. When a valid path is created it is added to the playlist and the loop for @mediadirs is exited with a last statement at 171, this bypasses the resetting of the local variables at line 175. On the next run through the main loop $trackurl will still contain the valid path just found, it will not be reassigned from $entry and will pass the if statement at line 139, then it is placed in the playlist again, an then the local variables are reset. Placing the line ($secs, $artist, $album, $title, $trackurl) = (); at the top of the while loop, around line 55, should fix this problem.
*** This bug has been confirmed by popular vote. ***
== Auto-comment from SVN commit #33903 to the slim repo by mherger == == http://svn.slimdevices.com/slim?view=revision&revision=33903 == Fixed Bug: 17933 Description: fix variable initialization
I don't think the fix is correct. Please see bug 18066 for more information.