Fixed bug in 'command' stanzas handler
git-svn-id: http://voip.null.ro/svn/yate@1197 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
parent
a208a6a09a
commit
821030aa77
|
@ -236,7 +236,7 @@ JBEvent* JBEngine::getEvent(u_int64_t time)
|
||||||
case JBEvent::IqCommandSet:
|
case JBEvent::IqCommandSet:
|
||||||
case JBEvent::IqCommandRes: {
|
case JBEvent::IqCommandRes: {
|
||||||
JabberID jid(event->to());
|
JabberID jid(event->to());
|
||||||
if (!jid.node() && !jid.resource() && !processCommand(event))
|
if (!processCommand(event))
|
||||||
return event;
|
return event;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -467,9 +467,10 @@ bool JBEngine::processDiscoInfo(JBEvent* event)
|
||||||
bool JBEngine::processCommand(JBEvent* event)
|
bool JBEngine::processCommand(JBEvent* event)
|
||||||
{
|
{
|
||||||
JBComponentStream* stream = event->stream();
|
JBComponentStream* stream = event->stream();
|
||||||
// Check if we have a stream and this engine is the destination
|
if (!(event && event->element() && event->child())) {
|
||||||
if (!(stream && event->element() && event->child()))
|
event->deref();
|
||||||
return false;
|
return true;
|
||||||
|
}
|
||||||
//TODO: Check if the engine is the destination.
|
//TODO: Check if the engine is the destination.
|
||||||
// The destination might be a user
|
// The destination might be a user
|
||||||
switch (event->type()) {
|
switch (event->type()) {
|
||||||
|
@ -491,7 +492,6 @@ bool JBEngine::processCommand(JBEvent* event)
|
||||||
// Release event
|
// Release event
|
||||||
event->deref();
|
event->deref();
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
JBComponentStream* JBEngine::findStream(const String& remoteName)
|
JBComponentStream* JBEngine::findStream(const String& remoteName)
|
||||||
|
|
|
@ -78,7 +78,7 @@ public:
|
||||||
JingleTransport, // http://www.google.com/transport/p2p
|
JingleTransport, // http://www.google.com/transport/p2p
|
||||||
Dtmf, // http://jabber.org/protocol/jingle/info/dtmf
|
Dtmf, // http://jabber.org/protocol/jingle/info/dtmf
|
||||||
DtmfError, // http://jabber.org/protocol/jingle/info/dtmf#errors
|
DtmfError, // http://jabber.org/protocol/jingle/info/dtmf#errors
|
||||||
Command, // http://jabber.org/protocol/admin#packets_notification
|
Command, // http://jabber.org/protocol/command
|
||||||
Count,
|
Count,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue