aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/tests/mgcp
diff options
context:
space:
mode:
authorJacob Erlbeck <jerlbeck@sysmocom.de>2013-12-09 14:32:03 +0100
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2013-12-13 13:48:04 +0100
commit2c2ca4df382110c4bebdb91d7410838fbf20d493 (patch)
tree241626de22b87eb2dadd0b5147e60b0241739407 /openbsc/tests/mgcp
parentba477d2ba3d6ff667eb38a8b42731a7886781266 (diff)
mgcp: Put local connection options into a struct
Currently the local connection options have been stored as a string. This patch replaces this string by a struct (that still contains a string) along with the parsed fields (only the packetization period at the moment). It also re-adds the calls to set_local_cx_options() to the handle_create_con() and handle_modify_con() functions. Except for the test program this has no side effects, since the LCO values aren't used yet.
Diffstat (limited to 'openbsc/tests/mgcp')
-rw-r--r--openbsc/tests/mgcp/mgcp_test.c9
-rw-r--r--openbsc/tests/mgcp/mgcp_test.ok8
2 files changed, 12 insertions, 5 deletions
diff --git a/openbsc/tests/mgcp/mgcp_test.c b/openbsc/tests/mgcp/mgcp_test.c
index bea977156..8b5e17ddc 100644
--- a/openbsc/tests/mgcp/mgcp_test.c
+++ b/openbsc/tests/mgcp/mgcp_test.c
@@ -319,7 +319,14 @@ static void test_messages(void)
endp->net_end.packet_duration_ms);
else
printf("Packet duration not set\n");
- printf("Requested packetization period not set\n");
+ if (endp->local_options.pkt_period_min ||
+ endp->local_options.pkt_period_max)
+ printf("Requested packetetization period: "
+ "%d-%d\n",
+ endp->local_options.pkt_period_min,
+ endp->local_options.pkt_period_max);
+ else
+ printf("Requested packetization period not set\n");
endp->net_end.packet_duration_ms = -1;
}
diff --git a/openbsc/tests/mgcp/mgcp_test.ok b/openbsc/tests/mgcp/mgcp_test.ok
index 509958aa1..24f9b336c 100644
--- a/openbsc/tests/mgcp/mgcp_test.ok
+++ b/openbsc/tests/mgcp/mgcp_test.ok
@@ -17,19 +17,19 @@ Testing MDCX1
Testing MDCX2
Testing CRCX
Packet duration not set
-Requested packetization period not set
+Requested packetetization period: 20-20
Testing MDCX3
Packet duration not set
Requested packetization period not set
Testing MDCX4
Packet duration not set
-Requested packetization period not set
+Requested packetetization period: 20-20
Testing MDCX4_PT1
Packet duration not set
-Requested packetization period not set
+Requested packetetization period: 20-40
Testing MDCX4_PT2
Packet duration not set
-Requested packetization period not set
+Requested packetetization period: 20-20
Testing MDCX4_PT3
Packet duration not set
Requested packetization period not set