Merge branch 'master' of gitorious.org:statusnet/mainline into 0.9.x

This commit is contained in:
Brion Vibber
2010-01-15 09:52:50 -08:00
7 changed files with 28 additions and 10 deletions

View File

@@ -70,7 +70,7 @@ class IoMaster
$classes = array();
if (Event::handle('StartIoManagerClasses', array(&$classes))) {
$classes[] = 'QueueManager';
if (common_config('xmpp', 'enabled')) {
if (common_config('xmpp', 'enabled') && !defined('XMPP_EMERGENCY_FLAG')) {
$classes[] = 'XmppManager'; // handles pings/reconnects
$classes[] = 'XmppConfirmManager'; // polls for outgoing confirmations
}

View File

@@ -157,7 +157,7 @@ abstract class QueueManager extends IoManager
}
// XMPP output handlers...
if (common_config('xmpp', 'enabled')) {
if (common_config('xmpp', 'enabled') && !defined('XMPP_EMERGENCY_FLAG')) {
$this->connect('jabber', 'JabberQueueHandler');
$this->connect('public', 'PublicQueueHandler');

View File

@@ -118,7 +118,11 @@ class XmppManager extends IoManager
*/
public function getSockets()
{
return array($this->conn->getSocket());
if ($this->conn) {
return array($this->conn->getSocket());
} else {
return array();
}
}
/**