Bug 18066 - Title information from M3U files are not saved
: Title information from M3U files are not saved
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Playlists
: 7.8.0
: PC Other
: -- normal with 1 vote (vote)
: 7.8.0
Assigned To: Michael Herger
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-01-15 10:13 UTC by hagan
Modified: 2014-02-08 22:26 UTC (History)
2 users (show)

See Also:
Category: ---


Attachments
Test playlist (8.41 KB, audio/x-mpegurl)
2014-02-06 22:33 UTC, hagan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description hagan 2014-01-15 10:13:07 UTC
There is a bug in the M3U parser Formats/Playlists/M3U.pm

This parser tries to extract the duration, artist, album and title from comment lines and saves them to the database as metadata for the trackurl.
But this doesn't work because the variables are defined within the entry loop and get lost when the next line with the trackurl is parsed.

I fixed this by moving the definition line "my ($secs, $artist, $album, $title, $trackurl);" before the "while" statement. But this should probably be reviewed to make sure the variables are cleared before the next entry.
Comment 1 hagan 2014-01-31 08:37:34 UTC
This is probably caused by a faulty fix for bug 17933 which ignores the possibility of multiple line entries.
Comment 2 Michael Herger 2014-02-05 06:03:59 UTC
Thanks - need to review this fix. There have been more reports of this in the forums.
http://forums.slimdevices.com/showthread.php?t=100890
Comment 3 Michael Herger 2014-02-06 06:38:54 UTC
Could you please attach a sample playlist which is exposing this misbehavior to this bug report? Thanks!
Comment 4 hagan 2014-02-06 22:33:31 UTC
Created attachment 7714 [details]
Test playlist

This playlist was working perfectly with squeezeboxserver-7.5.1, but it does not with the current version logitechmediaserver-7.8.0
Comment 5 Michael Herger 2014-02-07 05:35:01 UTC
Ok, thanks. I think I see a pattern: this is a playlist of remote streams only. Would you see the same problem with playlists of local tracks?
Comment 6 hagan 2014-02-07 08:10:20 UTC
I only noticed it with this file.
Perhaps the error does not show with other entries because they are already stored in the database and don't need to be read from the m3u file.
Comment 7 Michael Herger 2014-02-07 08:19:53 UTC
> Perhaps the error does not show with other entries because they are already
> stored in the database and don't need to be read from the m3u file.

Exactly. My assumption as well.
Comment 8 Michael Herger 2014-02-07 10:41:55 UTC
cedf697d25b76a9e4e43734ac2c580e8e02fd171
Ok, this time I hopefully fixed both, this issue and bug 17933.
Comment 9 Michael Herger 2014-02-08 22:26:19 UTC
*** Bug 17888 has been marked as a duplicate of this bug. ***