Commit 49854e9a authored by Bastien Nocera's avatar Bastien Nocera

plparser: Apply same check to remote text files as local ones

This was causing text files on remote locations not to be ignored when
parsing, so one would usually end up with a bunch of text files in their
playlists when they wouldn't be wanted.
parent 29cbef5d
This is an empty file that isn't really a playlist
This is an empty file that isn't really a playlist
......@@ -1857,8 +1857,9 @@ totem_pl_parser_parse_internal (TotemPlParser *parser,
}
DEBUG(file, g_print ("_get_mime_type_for_name for '%s' returned '%s'\n", uri, mimetype));
if (mimetype == NULL || strcmp (UNKNOWN_TYPE, mimetype) == 0
|| (g_file_is_native (file) && g_content_type_is_a (mimetype, "text/plain") != FALSE)) {
if (mimetype == NULL ||
strcmp (UNKNOWN_TYPE, mimetype) == 0 ||
g_content_type_is_a (mimetype, "text/plain") != FALSE) {
char *new_mimetype;
new_mimetype = my_g_file_info_get_mime_type_with_data (file, &data, parser);
if (new_mimetype) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment