fixup disconnected to use method
darcs-hash:20080705202412-5a68a-12ead3349425d70ec0a8349ebc3ce24b7a628dbc.gz
This commit is contained in:
parent
93fc218f79
commit
62db03d31f
@ -54,6 +54,7 @@ class XMPPDaemon {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function connect() {
|
function connect() {
|
||||||
|
|
||||||
$connect_to = ($this->host) ? $this->host : $this->server;
|
$connect_to = ($this->host) ? $this->host : $this->server;
|
||||||
|
|
||||||
$this->log(LOG_INFO, "Connecting to $connect_to on port $this->port");
|
$this->log(LOG_INFO, "Connecting to $connect_to on port $this->port");
|
||||||
@ -63,6 +64,7 @@ class XMPPDaemon {
|
|||||||
if (!$this->conn) {
|
if (!$this->conn) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
return !$this->conn->isDisconnected();
|
return !$this->conn->isDisconnected();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -71,7 +73,7 @@ class XMPPDaemon {
|
|||||||
static $parts = array('message', 'presence',
|
static $parts = array('message', 'presence',
|
||||||
'end_stream', 'session_start');
|
'end_stream', 'session_start');
|
||||||
|
|
||||||
while(!$this->conn->disconnected) {
|
while(!$this->conn->isDisconnected()) {
|
||||||
|
|
||||||
$payloads = $this->conn->processUntil($parts, 10);
|
$payloads = $this->conn->processUntil($parts, 10);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user