summaryrefslogtreecommitdiff
path: root/scripts/xmppdaemon.php
diff options
context:
space:
mode:
authorRobin Millette <millette@controlyourself.ca>2009-04-17 16:47:18 +0000
committerRobin Millette <millette@controlyourself.ca>2009-04-17 16:47:18 +0000
commit2eb1eb86838b47af7305dbd21a181e63bcd58418 (patch)
tree5b0970b274b9453f4f76225783f85792b36f049a /scripts/xmppdaemon.php
parent21873b806d6c5cf3e55ea10e49959c944f708688 (diff)
parent34d904b180e5caa17eb945292a8a64656424d5d0 (diff)
Merge branch '0.7.x' of git@gitorious.org:laconica/dev into 0.7.x
Diffstat (limited to 'scripts/xmppdaemon.php')
-rwxr-xr-xscripts/xmppdaemon.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/scripts/xmppdaemon.php b/scripts/xmppdaemon.php
index ef3f8c63d..0ce2f2a28 100755
--- a/scripts/xmppdaemon.php
+++ b/scripts/xmppdaemon.php
@@ -321,6 +321,13 @@ class XMPPDaemon extends Daemon
}
}
+// Abort immediately if xmpp is not enabled, otherwise the daemon chews up
+// lots of CPU trying to connect to unconfigured servers
+if (common_config('xmpp','enabled')==false) {
+ print "Aborting daemon - xmpp is disabled\n";
+ exit();
+}
+
ini_set("max_execution_time", "0");
ini_set("max_input_time", "0");
set_time_limit(0);