*** empty log message ***
git-svn-id: http://voip.null.ro/svn/yate@146 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
parent
3f3f86750f
commit
814562e4e7
|
@ -37,11 +37,14 @@ SIPTransaction::SIPTransaction(SIPMessage* message, SIPEngine* engine, bool outg
|
|||
Debug(DebugAll,"SIPTransaction::SIPTransaction(%p,%p) [%p]",message,engine,this);
|
||||
if (m_firstMessage) {
|
||||
m_firstMessage->ref();
|
||||
const NamedString* br = message->getParam("Via","branch");
|
||||
if (br)
|
||||
m_branch = *br;
|
||||
const NamedString* ns = message->getParam("Via","branch");
|
||||
if (ns)
|
||||
m_branch = *ns;
|
||||
if (!m_branch.startsWith("z9hG4bK"))
|
||||
m_branch.clear();
|
||||
const HeaderLine* hl = message->getHeader("Call-ID");
|
||||
if (hl)
|
||||
m_callid = *hl;
|
||||
}
|
||||
m_invite = (getMethod() == "INVITE");
|
||||
m_engine->TransList.append(this);
|
||||
|
@ -209,6 +212,12 @@ SIPEvent* SIPTransaction::getEvent(int state, int timeout)
|
|||
e = new SIPEvent(m_lastMessage,this);
|
||||
changeState(Trying);
|
||||
}
|
||||
else if (getMethod() == "CANCEL") {
|
||||
setLatestMessage(new SIPMessage(m_firstMessage, 100, "Trying"));
|
||||
m_lastMessage->deref();
|
||||
e = new SIPEvent(m_lastMessage,this);
|
||||
changeState(Trying);
|
||||
}
|
||||
break;
|
||||
}
|
||||
return e;
|
||||
|
|
|
@ -419,6 +419,13 @@ public:
|
|||
inline const String& getBranch() const
|
||||
{ return m_branch; }
|
||||
|
||||
/**
|
||||
* The call ID may identify this transaction
|
||||
* @return The Call-ID parameter taken from the message
|
||||
*/
|
||||
inline const String& getCallID() const
|
||||
{ return m_callid; }
|
||||
|
||||
/**
|
||||
* The local tag that may identify this transaction
|
||||
* @return The local tag parameter
|
||||
|
@ -517,6 +524,7 @@ protected:
|
|||
SIPMessage* m_lastMessage;
|
||||
SIPEngine* m_engine;
|
||||
String m_branch;
|
||||
String m_callid;
|
||||
String m_tag;
|
||||
void *m_private;
|
||||
};
|
||||
|
@ -556,6 +564,13 @@ public:
|
|||
inline bool isOutgoing() const
|
||||
{ return m_message && m_message->isOutgoing(); }
|
||||
|
||||
/**
|
||||
* Check if the message is an incoming message
|
||||
* @return True if the message is coming from remote
|
||||
*/
|
||||
inline bool isIncoming() const
|
||||
{ return m_message && !m_message->isOutgoing(); }
|
||||
|
||||
/**
|
||||
* Get the pointer to the endpoint this event uses
|
||||
*/
|
||||
|
|
Loading…
Reference in New Issue