diff --git a/src/filescanner.c b/src/filescanner.c index 888d031d..6cfa6f16 100644 --- a/src/filescanner.c +++ b/src/filescanner.c @@ -259,9 +259,11 @@ process_media_file(char *file, time_t mtime, off_t size, int compilation) if ((strcmp(ext, ".pls") == 0) || (strcmp(ext, ".url") == 0)) { + mfi.data_kind = 1; /* url/stream */ + ret = scan_url_file(file, &mfi); - if (ret == 0) - mfi.data_kind = 1; /* url/stream */ + if (ret < 0) + goto out; } else if ((strcmp(ext, ".png") == 0) || (strcmp(ext, ".jpg") == 0)) diff --git a/src/filescanner_urlfile.c b/src/filescanner_urlfile.c index 558473b4..59dd28e4 100644 --- a/src/filescanner_urlfile.c +++ b/src/filescanner_urlfile.c @@ -106,8 +106,6 @@ scan_url_file(char *file, struct media_file_info *mfi) { DPRINTF(E_WARN, L_SCAN, "Could not read bitrate\n"); - free(mfi->title); - free(mfi->url); return -1; }