summaryrefslogtreecommitdiff
path: root/functions.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2008-02-24 12:34:32 +0100
committerAndrew Dolgov <[email protected]>2008-02-24 12:34:32 +0100
commit9a91a51e0dcfd1a2e56c684531b75a566d76bfe6 (patch)
treefa8c851ab4a209b647f32a65450f61e281de2797 /functions.php
parent3c2d7945ae04e219eaa6206c745e314b1492e574 (diff)
update function: only call pcntl_alarm() if it is defined
Diffstat (limited to 'functions.php')
-rw-r--r--functions.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/functions.php b/functions.php
index b4a540e7e..06d7e7a74 100644
--- a/functions.php
+++ b/functions.php
@@ -5365,10 +5365,10 @@
// We setup a alarm to alert if the feed take more than 300s to update.
// => HANG alarm.
- if(!$from_http) pcntl_alarm(300);
+ if(!$from_http && function_exists('pcntl_alarm')) pcntl_alarm(300);
update_rss_feed($link, $line["feed_url"], $line["id"], true);
// Cancel the alarm (the update went well)
- if(!$from_http) pcntl_alarm(0);
+ if(!$from_http && function_exists('pcntl_alarm')) pcntl_alarm(0);
sleep(1); // prevent flood (FIXME make this an option?)
}