summaryrefslogtreecommitdiff
path: root/apps/tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/tree.c')
-rw-r--r--apps/tree.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/tree.c b/apps/tree.c
index 4b23bbef89..6d18d79da3 100644
--- a/apps/tree.c
+++ b/apps/tree.c
@@ -1222,9 +1222,10 @@ void bookmark_play(char *resume_file, int index, int offset, int seed,
1222 char *filename) 1222 char *filename)
1223{ 1223{
1224 int i; 1224 int i;
1225 int len=strlen(resume_file); 1225 char* suffix = strrchr(resume_file, '.');
1226 1226
1227 if (!strcasecmp(&resume_file[len-4], ".m3u")) 1227 if (suffix != NULL &&
1228 (!strcasecmp(suffix, ".m3u") || !strcasecmp(suffix, ".m3u8")))
1228 { 1229 {
1229 /* Playlist playback */ 1230 /* Playlist playback */
1230 char* slash; 1231 char* slash;