summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2013-03-11 14:14:28 +0400
committerAndrew Dolgov <[email protected]>2013-03-11 14:14:28 +0400
commit96f98cb09137cc4a2a074c2c9cac3fd6eed50677 (patch)
treeb2d1972dd73836e242eefcbfd5edcff0c5769a62 /include
parent41acdf4c11f60e0e6a0012e5d62ce82922eee994 (diff)
escape fetch error message before saving in the db (closes #550)
Diffstat (limited to 'include')
-rw-r--r--include/rssfuncs.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/rssfuncs.php b/include/rssfuncs.php
index 2b13f9457..0b1d06564 100644
--- a/include/rssfuncs.php
+++ b/include/rssfuncs.php
@@ -238,8 +238,10 @@
_debug("update_rss_feed: unable to fetch: $fetch_last_error");
}
+ $error_escaped = db_escape_string($fetch_last_error);
+
db_query($link,
- "UPDATE ttrss_feeds SET last_error = '$fetch_last_error',
+ "UPDATE ttrss_feeds SET last_error = '$error_escaped',
last_updated = NOW() WHERE id = '$feed'");
return;