From: garvinhicking <garvinhicking>
Date: Thu, 3 Nov 2005 13:23:05 +0000 (+0000)
Subject: patch by kris
X-Git-Tag: 1.0~331
X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=396a260d41e61cef5217040ab9dd4bc7a51482c1;p=s9y.git

patch by kris
---

diff --git a/bundled-libs/Onyx/RSS.php b/bundled-libs/Onyx/RSS.php
index 11c2cb6..2db05c7 100644
--- a/bundled-libs/Onyx/RSS.php
+++ b/bundled-libs/Onyx/RSS.php
@@ -129,12 +129,12 @@ class ONYX_RSS
          clearstatcache();
          
          require_once S9Y_PEAR_PATH . 'HTTP/Request.php';
-         $req = &new HTTP_Request($uri);
+         $req = &new HTTP_Request($uri, array('allowRedirects' => true, 'maxRedirects' => 5));
          $res = $req->sendRequest();
         
          if (PEAR::isError($res) || $req->getResponseCode() != '200')
          {
-            $this->raiseError((__LINE__-2), ONYX_ERR_INVALID_URI);
+            $this->raiseError((__LINE__-2), ONYX_ERR_INVALID_URI . ' (#' . $req->getResponseCode() . ')');
             return false;
          }
 
diff --git a/docs/NEWS b/docs/NEWS
index 00abd4c..b9153cc 100644
--- a/docs/NEWS
+++ b/docs/NEWS
@@ -10,6 +10,8 @@ Version 1.0 ()
 Version 0.9.1 ()
 ------------------------------------------------------------------------
 
+    * Make Onyx RSS parser interpret HTTP redirecty. (Kristian Köhntopp)
+
     * Added blogger.com importer by Jawish Hameed
 
     * Fix visitor tracking in statistics plugin (garvinhicking)