|
|
@ -573,15 +573,11 @@
|
|
|
|
$auth_login = db_fetch_result($result, 0, "auth_login");
|
|
|
|
$auth_login = db_fetch_result($result, 0, "auth_login");
|
|
|
|
$auth_pass = db_fetch_result($result, 0, "auth_pass");
|
|
|
|
$auth_pass = db_fetch_result($result, 0, "auth_pass");
|
|
|
|
|
|
|
|
|
|
|
|
if (ALLOW_SELECT_UPDATE_METHOD) {
|
|
|
|
if (DEFAULT_UPDATE_METHOD == "1") {
|
|
|
|
if (ENABLE_SIMPLEPIE) {
|
|
|
|
|
|
|
|
$use_simplepie = $update_method != 1;
|
|
|
|
$use_simplepie = $update_method != 1;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
$use_simplepie = $update_method == 2;
|
|
|
|
$use_simplepie = $update_method == 2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
|
|
|
|
$use_simplepie = ENABLE_SIMPLEPIE;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (defined('DAEMON_EXTENDED_DEBUG') || $_REQUEST['xdebug']) {
|
|
|
|
if (defined('DAEMON_EXTENDED_DEBUG') || $_REQUEST['xdebug']) {
|
|
|
|
_debug("use simplepie: $use_simplepie (feed setting: $update_method)\n");
|
|
|
|
_debug("use simplepie: $use_simplepie (feed setting: $update_method)\n");
|
|
|
@ -3961,7 +3957,7 @@
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
error_reporting(0);
|
|
|
|
error_reporting(0);
|
|
|
|
if (ENABLE_SIMPLEPIE) {
|
|
|
|
if (DEFAULT_UPDATE_INTERVAL == "1") {
|
|
|
|
$rss = new SimplePie();
|
|
|
|
$rss = new SimplePie();
|
|
|
|
$rss->set_useragent(SIMPLEPIE_USERAGENT . MAGPIE_USER_AGENT_EXT);
|
|
|
|
$rss->set_useragent(SIMPLEPIE_USERAGENT . MAGPIE_USER_AGENT_EXT);
|
|
|
|
// $rss->set_timeout(MAGPIE_FETCH_TIME_OUT);
|
|
|
|
// $rss->set_timeout(MAGPIE_FETCH_TIME_OUT);
|
|
|
@ -3975,7 +3971,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
if ($rss) {
|
|
|
|
if ($rss) {
|
|
|
|
|
|
|
|
|
|
|
|
if (ENABLE_SIMPLEPIE) {
|
|
|
|
if (DEFAULT_UPDATE_METHOD == "1") {
|
|
|
|
$items = $rss->get_items();
|
|
|
|
$items = $rss->get_items();
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
$items = $rss->items;
|
|
|
|
$items = $rss->items;
|
|
|
@ -3990,7 +3986,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
$latest_item = $items[0];
|
|
|
|
$latest_item = $items[0];
|
|
|
|
|
|
|
|
|
|
|
|
if (ENABLE_SIMPLEPIE) {
|
|
|
|
if (DEFAULT_UPDATE_METHOD == "1") {
|
|
|
|
$last_title = $latest_item->get_title();
|
|
|
|
$last_title = $latest_item->get_title();
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
$last_title = $latest_item["title"];
|
|
|
|
$last_title = $latest_item["title"];
|
|
|
@ -3998,7 +3994,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
$latest_version = trim(preg_replace("/(Milestone)|(completed)/", "", $last_title));
|
|
|
|
$latest_version = trim(preg_replace("/(Milestone)|(completed)/", "", $last_title));
|
|
|
|
|
|
|
|
|
|
|
|
if (ENABLE_SIMPLEPIE) {
|
|
|
|
if (DEFAULT_UPDATE_METHOD == "1") {
|
|
|
|
$release_url = sanitize_rss($link, $latest_item->get_link());
|
|
|
|
$release_url = sanitize_rss($link, $latest_item->get_link());
|
|
|
|
$content = sanitize_rss($link, $latest_item->get_description());
|
|
|
|
$content = sanitize_rss($link, $latest_item->get_description());
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|