summaryrefslogtreecommitdiff
path: root/include/rssfuncs.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2013-04-18 11:35:58 +0400
committerAndrew Dolgov <[email protected]>2013-04-18 11:36:13 +0400
commit3f6f085769de4df84e831eefb767c4cdbfb7c64b (patch)
treee005de1467e85bb783a78563900bb92558f0edab /include/rssfuncs.php
parentd0d86316ee5db103afcc77406e45abb26a1978ea (diff)
add better gzdecode support for php native fetch, use curl under open_basedir
Diffstat (limited to 'include/rssfuncs.php')
-rw-r--r--include/rssfuncs.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/rssfuncs.php b/include/rssfuncs.php
index 537a4c338..494e050a6 100644
--- a/include/rssfuncs.php
+++ b/include/rssfuncs.php
@@ -304,6 +304,14 @@
$no_cache ? FEED_FETCH_NO_CACHE_TIMEOUT : FEED_FETCH_TIMEOUT,
$force_refetch ? 0 : max($last_updated_timestamp, $cache_timestamp));
+ global $fetch_curl_used;
+
+ if (!$fetch_curl_used) {
+ $tmp = @gzdecode($feed_data);
+
+ if ($tmp) $feed_data = $tmp;
+ }
+
if ($debug_enabled) {
_debug("update_rss_feed: fetch done.");
}