From 2af7296723c624143ce41e58242e71580675209f Mon Sep 17 00:00:00 2001 From: ejurgensen Date: Mon, 23 Mar 2020 20:08:27 +0100 Subject: [PATCH] [library] Ignore RSS items without URL's --- src/library/rssscanner.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/library/rssscanner.c b/src/library/rssscanner.c index b7232d2e..b59866ff 100644 --- a/src/library/rssscanner.c +++ b/src/library/rssscanner.c @@ -354,7 +354,7 @@ mfi_metadata_fixup(struct media_file_info *mfi, struct rss_item_info *ri, const struct tm tm; // Always take the meta from media file if possible; some podcasts (Apple) can - // use mp4 streams which tend not to have decent tags so in those cases take + // use mp4 streams which tend not to have decent tags so in those cases take // info from the RSS and not the stream if (!mfi->artist) mfi->artist = safe_strdup(feed_author); @@ -437,6 +437,12 @@ rss_save(struct playlist_info *pli, int *count, enum rss_scan_type scan_type) return -1; } + if (!ri.url) + { + DPRINTF(E_WARN, L_LIB, "Missing URL for item '%s' (date %s) in RSS feed '%s'\n", ri.title, ri.pubdate, feed_title); + continue; + } + db_pl_add_item_bypath(pli->id, ri.url); (*count)++;