Take into account parameters of chan.startup even if it happens to be received after call.execute.

git-svn-id: http://voip.null.ro/svn/yate@1477 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2007-11-19 21:37:23 +00:00
parent d32c220960
commit 69aaddbbf2
5 changed files with 26 additions and 17 deletions

View File

@ -37,7 +37,8 @@ bool ChanAssistList::received(Message& msg, int id)
switch (id) {
case Startup:
if (ca) {
Debug(this,DebugMild,"Channel '%s' already assisted!",chanId->c_str());
Debug(this,DebugNote,"Channel '%s' already assisted!",chanId->c_str());
ca->msgStartup(msg);
return false;
}
ca = create(msg,*chanId);

View File

@ -148,7 +148,7 @@ public:
/**
* Process the chan.startup message
* @param msg First channel message
* @param msg First channel message, may be received after call.execute
*/
virtual void msgStartup(Message& msg);
@ -160,7 +160,7 @@ public:
/**
* Process the call.execute message, copy any parameters needed later
* @param msg Call execute message
* @param msg Call execute message, may be received before chan.startup
*/
virtual void msgExecute(Message& msg);

View File

@ -799,12 +799,20 @@ void PBXAssist::msgStartup(Message& msg)
NamedString* status = msg.getParam("status");
if (status && (*status == "outgoing")) {
// switch them over so we have them right for later operations
m_keep.setParam("caller",msg.getValue("called"));
m_keep.setParam("called",msg.getValue("caller"));
const char* tmp = msg.getValue("called");
if (tmp)
m_keep.setParam("caller",tmp);
tmp = msg.getValue("caller");
if (tmp)
m_keep.setParam("called",tmp);
}
else {
m_keep.setParam("called",msg.getValue("called"));
m_keep.setParam("caller",msg.getValue("caller"));
const char* tmp = msg.getValue("called");
if (tmp)
m_keep.setParam("called",tmp);
tmp = msg.getValue("caller");
if (tmp)
m_keep.setParam("caller",tmp);
}
}

View File

@ -1,3 +1,3 @@
AppVerName=Yate 1.3.0 - 1
AppVersion=1.3.0
VersionInfoVersion=1.3.0.1
AppVerName=Yate 2.0.0 - 1
AppVersion=2.0.0
VersionInfoVersion=2.0.0.1

View File

@ -10,19 +10,19 @@
#define __YATEVERSN_H
/* Version numbers */
#define YATE_MAJOR 1
#define YATE_MINOR 3
#define YATE_MAJOR 2
#define YATE_MINOR 0
#define YATE_BUILD 0
/* Version strings */
#define YATE_MAJOR_S "1"
#define YATE_MINOR_S "3"
#define YATE_MAJOR_S "2"
#define YATE_MINOR_S "0"
#define YATE_BUILD_S "0"
#define YATE_VERSION "1.3.0"
#define YATE_VERSION "2.0.0"
#define YATE_RELEASE "1"
/* Windows version resource - file and string style */
#define YATE_WINVER_F 1,3,0,1
#define YATE_WINVER_S "1, 3, 0, 1\0"
#define YATE_WINVER_F 2,0,0,1
#define YATE_WINVER_S "2, 0, 0, 1\0"
#endif /* __YATEVERSN_H */