Thank you Stefan for detailed response.
It's for billing.
"other_id = getLocalTag() + "_c2d";" is a good solution.
On 12.12.2011 17:05, Stefan Sayer wrote:
o Самусенко Андрей on 12/12/2011 12:31 PM:
Hi.
There is some method to match two click2dial calls?
match from where? from outside, e.g. for billing purposes?
from the inside you can use relayEvent(...) to send an event to the
other leg, or access AmB2BSession::other_leg to something else with it.
if you have monitoring module loaded, you can use the b2b_leg property
to get the other id (the other local tag).
If no, may be to use same from_tag in both legs?
not such a good idea. The local tag is used to identify the sessions
locally, everything will get confused (e.g. events only going into one
call) if you use the same here. You could the first leg's ID with
something added, though, e.g.:
diff --git a/core/AmB2BSession.cpp b/core/AmB2BSession.cpp
index 6a78e67..d97863e 100644
--- a/core/AmB2BSession.cpp
+++ b/core/AmB2BSession.cpp
@@ -1018,7 +1018,8 @@ void AmB2BCallerSession::createCalleeSession() {
AmSipDialog& callee_dlg = callee_session->dlg;
- other_id = AmSession::getNewId();
+ other_id = getLocalTag() + "_b2b_1";
+ // other_id = AmSession::getNewId();
callee_dlg.local_tag = other_id;
callee_dlg.callid = AmSession::getNewId();
Stefan
_______________________________________________
Sems mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/sems