Change in ...osmo-ttcn3-hacks[master]: bscnat: Fix race condition in TC_ctrl_location

laforge gerrit-no-reply at lists.osmocom.org
Thu Jun 13 15:32:08 UTC 2019


laforge has submitted this change and it was merged. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/14440 )

Change subject: bscnat: Fix race condition in TC_ctrl_location
......................................................................

bscnat: Fix race condition in TC_ctrl_location

Change-Id: Ifb5a2a9936fff94511a6bd11bd8e155a3d3e2d82
---
M bsc-nat/BSC_MS_Simulation.ttcn
1 file changed, 5 insertions(+), 0 deletions(-)

Approvals:
  Jenkins Builder: Verified
  laforge: Looks good to me, approved



diff --git a/bsc-nat/BSC_MS_Simulation.ttcn b/bsc-nat/BSC_MS_Simulation.ttcn
index 453f304..0582576 100644
--- a/bsc-nat/BSC_MS_Simulation.ttcn
+++ b/bsc-nat/BSC_MS_Simulation.ttcn
@@ -10,6 +10,7 @@
  * SPDX-License-Identifier: GPL-2.0-or-later
  */
 
+import from Osmocom_Types all;
 import from IPL4asp_Types all;
 
 import from IPA_Emulation all;
@@ -83,6 +84,10 @@
 	f_ctrl_trap(SCCPLITE_IPA_CTRL, "bts.0.location-state",
 		    "1234567,fix3d,0.340000,0.560000,0.780000,operational,unlocked,on,001,01");
 	f_ctrl_exp_set(SCCPLITE_IPA_CTRL, "rf_locked", "1", "1");
+	/* Leave some time for SET_REPLY to reach the other side before closing
+	   conn towards BSC-NAT, otherwise TCP FIN is sent before SET_REPLY and
+	   bsc-nat sends a CTRL ERR to whoever sent the SET cmd. */
+	f_sleep(1.0);
 }
 
 function main(charstring remote_ip, PortNumber remote_port,

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/14440
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ifb5a2a9936fff94511a6bd11bd8e155a3d3e2d82
Gerrit-Change-Number: 14440
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at gnumonks.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190613/8055853a/attachment.html>


More information about the gerrit-log mailing list