Bug 1282 - compatibility with WMP 10 M3U playlists
: compatibility with WMP 10 M3U playlists
Status: CLOSED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Playlists
: 6.0.0
: PC Windows XP
: P2 normal (vote)
: ---
Assigned To: Vidur Apparao
:
Depends on:
Blocks: 781
  Show dependency treegraph
 
Reported: 2005-04-02 04:11 UTC by Geert Nijs
Modified: 2008-08-18 10:54 UTC (History)
0 users

See Also:
Category: ---


Attachments
clean up relative paths (960 bytes, patch)
2005-05-06 23:54 UTC, KDF
Details | Diff
corrected for windows. (915 bytes, patch)
2005-05-07 00:16 UTC, KDF
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Geert Nijs 2005-04-02 04:11:16 UTC
In Windows Media Player, you can also create M3U playlists (save as M3U).
These playlists appear in SlimServer, but when you click on them,
WHOOPP..SlimServer goes to 1.5 gig memory utilisation and locks up my whole
computer. Must kill slimserver to recover.

I have compared both a M3U playlist created by SlimServer and one created by
Windows Media player and the only difference i can see, is that WMP creates
relative paths and SlimServer creates absulute paths, see below:
A playlist by SlimServer:
#CURTRACK 0
#EXTM3U
#EXTINF:-1,Politik
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-01-Politik.mp3
#EXTINF:-1,In My Place
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-02-In My Place.mp3
#EXTINF:-1,God Put a Smile Upon Your Face
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-03-God Put a Smile Upon Your Face.mp3
#EXTINF:-1,The Scientist
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-04-The Scientist.mp3
#EXTINF:-1,Clocks
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-05-Clocks.mp3
#EXTINF:-1,Daylight
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-06-Daylight.mp3
#EXTINF:-1,Green Eyes
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-07-Green Eyes.mp3
#EXTINF:-1,Warning Sign
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-08-Warning Sign.mp3
#EXTINF:-1,A Whisper
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-09-A Whisper.mp3
#EXTINF:-1,A Rush of Blood to the Head
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-10-A Rush of Blood to the Head.mp3
#EXTINF:-1,Amsterdam
G:\MySounds\ColdPlay\A Rush of Blood to the Head\Coldplay-A Rush of Blood to the
Head-11-Amsterdam.mp3

A playlist by WMP:
#EXTM3U
#EXTINF:0,Laurent Garnier-the sound of the big babou.mp3
..\Laurent Garnier-the sound of the big babou.mp3

#EXTINF:0,Chris Raven - I Know You Love Me Too.mp3
..\___UNCLASSIFIED___\Chris Raven - I Know You Love Me Too.mp3

#EXTINF:0,Planet Fusion - Innocent Games.mp3
..\___UNCLASSIFIED___\Planet Fusion - Innocent Games.mp3

#EXTINF:0,Planet Perfecto feat. Grace - Not Over Yet '99!!s.mp3
..\___UNCLASSIFIED___\Planet Perfecto feat. Grace - Not Over Yet '99!!s.mp3

#EXTINF:0,Shaft - Mucho mambo.mp3
..\___UNCLASSIFIED___\Shaft - Mucho mambo.mp3

#EXTINF:0,DJ Serch & Pascal - Monotone (Original Extended Mix).mp3
..\___UNCLASSIFIED___\DJ Serch & Pascal - Monotone (Original Extended Mix).mp3

#EXTINF:0,Yomanda - Synth & Strings.mp3
..\___UNCLASSIFIED___\Yomanda - Synth & Strings.mp3

#EXTINF:0,CJ Bolland - Sugar Is Sweeter.mp3
..\___UNCLASSIFIED___\CJ Bolland - Sugar Is Sweeter.mp3



I guess, SlimServer locks up or has a memory leak on this relative path thing...
I have tested it with the lastest 6.1.0 release.
Comment 1 Geert Nijs 2005-04-02 04:47:05 UTC
Whats even more:
I have changed the relative Windows M3U file into an absolute file (using a text
editor) and then the playlist gets loaded into SlimServer without any problems...

CHANGED:

#EXTM3U
#EXTINF:0,Tchaikovsky-Martha Argerich, piano-Piano Concerto #1 - Allegro non
troppo.MP3
..\Tchaikovsky\Martha Argerich, piano\Tchaikovsky-Martha Argerich, piano-Piano
Concerto #1 - Allegro non troppo.MP3

#EXTINF:0,Mozart - Rondo Alla Turca.mp3
..\Classical\Mozart - Rondo Alla Turca.mp3

#EXTINF:0,Chopin, Fr�d�ric-The Very Best of Chopin-Waltz in C sharp minor.mp3
..\Chopin, Fr�d�ric\The Very Best of Chopin\Chopin, Fr�d�ric-The Very Best of
Chopin-Waltz in C sharp minor.mp3

INTO:

#EXTM3U
#EXTINF:0,Tchaikovsky-Martha Argerich, piano-Piano Concerto #1 - Allegro non
troppo.MP3
G:\MySounds\Tchaikovsky\Martha Argerich, piano\Tchaikovsky-Martha Argerich,
piano-Piano Concerto #1 - Allegro non troppo.MP3

#EXTINF:0,Mozart - Rondo Alla Turca.mp3
G:\MySounds\Classical\Mozart - Rondo Alla Turca.mp3

#EXTINF:0,Chopin, Fr�d�ric-The Very Best of Chopin-Waltz in C sharp minor.mp3
G:\MySounds\Chopin, Fr�d�ric\The Very Best of Chopin\Chopin, Fr�d�ric-The Very
Best of Chopin-Waltz in C sharp minor.mp3


and then it works....
Comment 2 Geert Nijs 2005-04-02 04:48:40 UTC
PS. My playlists are in the directory:

G:\MySounds\MyPlaylists
Comment 3 Marc Sherman 2005-04-14 05:12:20 UTC
The severity of this bug should be changed from Enhancement to Normal -- this is
a regression from 5.4.1.  All of my playlists are relative paths*, and they work
with 5.4.1.

* I create them with scripts on my linux box using relative paths, so that they
can be used regardless of the mount-point on both linux and windows boxes on my
network.
Comment 4 KDF 2005-05-06 18:41:35 UTC
ok, I know what is going on with this now (affects bug 1506 too)
given a playlist item of ../../music/artist-song.mp3

this would be converted to /playlistdir/../../music/artist-song.mp3

this messes up the fileURL, thus confusing 6.0+ since it depends on fileURL as a
track identifier. 5.4.1 worked, but STILL causes track count to increment due to
the differing fileUrl

fixPath should probably be changed to translate the path correctly
Comment 5 KDF 2005-05-06 23:54:46 UTC
Created attachment 497 [details]
clean up relative paths

ok, File::Spec::rel2abs is supposed to take relative paths into absolute, but
it appears to be broken for osx and linux.  It might work for windows, but I
haven't tested other than the fact that the output looks right.

the problem was that paths would be like so:
c:\playlists\..\music\file.mp3, which doesn't match c:\music\file.mp3, even
thought they point to the same file.  This causes the db to create a new track,
and it has problems dealing with the \..\ in the path.	In 5.4.1 this problem
didn't happen, but we DID see track counts increase (inexplicably at the time).


what I've done here is let rel2abs do its thing for windows, and for others
simply strip the path back for each /../ in the path.  This now works for the
test files i've set up here, but it definitely needs some testing to be sure
its ok for the rest.  The failure mode is a deep recusion into DBI code (big
memory use and 100% cpu lockup) so we need to make sure this works, even tho
this is the same failure mode we have now.

this should also fix bug 1506
Comment 6 KDF 2005-05-07 00:16:44 UTC
Created attachment 498 [details]
corrected for windows.

I was using the wrong variable for rel2abs.  this has been now tested in linux
and windows, with an m3u and wpl containing relative paths. the wpl was
generated by wmp 10
Comment 7 Dan Sully 2005-05-22 12:17:58 UTC
Fix from kdf commited in subversion change 3280.
Comment 8 Chris Owens 2008-03-11 11:28:05 UTC
This bug was marked resolved in Slimserver 6.1, which is several versions ago.  If you're still seeing this bug, please re-open it.  Thanks!