Comment 14 for bug 181553

Revision history for this message
Fred Reiss (frr42) wrote : Re: Totem ignores LF in Windows m3u playlists but not CR/LF

Please reopen this bug!

Many Internet radio stations change servers frequently, and the the only way to get an updated server list is to download an m3u or .pls file. When I want to listen to internet radio, it's a real pain to have to download a playlist file, open it up in a text editor, and change the carriage returns to newlines.

The cause of the problem appears to be in totem-pl-parser/plparse/totem-pl-parser-pls.c, lines 161 to 167:

 /* figure out whether we're a unix pls or dos pls */
 if (strstr(contents,"\x0d") == NULL) {
  split_char = "\n";
 } else {
  split_char = "\x0d\n";
  dos_mode = TRUE;
 }
 lines = g_strsplit (contents, split_char, 0);

This if statement should have a third branch to account for files that use \r as a line separator.