From 85469e1baa26347e12f7456fc729a1bc32c21066 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Thu, 11 Nov 2010 16:21:53 +0300 Subject: [PATCH] try to validate feed-specific icon before adding it to the database --- functions.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/functions.php b/functions.php index 8f60254b3..2102836f8 100644 --- a/functions.php +++ b/functions.php @@ -728,7 +728,9 @@ } if ($icon_url && $orig_icon_url != $icon_url) { - db_query($link, "UPDATE ttrss_feeds SET icon_url = '$icon_url' WHERE id = '$feed'"); + if (USE_CURL_FOR_ICONS || url_validate($icon_url)) { + db_query($link, "UPDATE ttrss_feeds SET icon_url = '$icon_url' WHERE id = '$feed'"); + } } if (defined('DAEMON_EXTENDED_DEBUG') || $_REQUEST['xdebug']) {