aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2015-12-03 13:54:40 +0100
committerHarald Welte <laforge@gnumonks.org>2015-12-03 13:54:40 +0100
commit474d83e21a2ae03614af946082a1384ed115428f (patch)
tree4e5115b2f216f0be29a5744aca933877165259c4
parent79b7947191825180504d97d2b7101063fbfd363b (diff)
gsm_call_fsm: Add get_callref method to GsmCallFsm
... and obtain the call references into the GsmCallConnector
-rw-r--r--gsm_call_fsm.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/gsm_call_fsm.py b/gsm_call_fsm.py
index 92aab7e..83e2599 100644
--- a/gsm_call_fsm.py
+++ b/gsm_call_fsm.py
@@ -204,6 +204,8 @@ class GsmCallFsm(pykka.ThreadingActor):
self.start_mt_call(message['calling'], message['called'])
elif message['type'] == 'connect_rtp':
self.connect_rtp(message['rtp'])
+ elif message['type'] == 'get_callref':
+ return self.callref
else:
raise Exception('mncc', 'Unknown message %s' % message)
@@ -217,6 +219,8 @@ class GsmCallConnector(pykka.ThreadingActor):
self.call_a = GsmCallFsm.start(self.mncc_act, self.actor_ref, self.rtp_bridge)
print 'Starting Call B actor'
self.call_b = GsmCallFsm.start(self.mncc_act, self.actor_ref, self.rtp_bridge)
+ self.callref_a = self.call_a.ask({'type':'get_callref'})
+ self.callref_b = self.call_b.ask({'type':'get_callref'})
self.state_a = self_state_b = 'NULL'
self.rtp_a = self.rtp_b = None