GGSN_Tests: Make sure f_init() body is traversed only once
We don't want the sequence numbers to be random-reinitialized on every test case, but only once.
This commit is contained in:
parent
5438b9dc27
commit
0be142b7bf
|
@ -40,6 +40,8 @@ module GGSN_Tests {
|
|||
port GTPC_PT GTPC;
|
||||
port GTPU_PT GTPU;
|
||||
|
||||
var boolean g_initialized := false;
|
||||
|
||||
var OCT1 g_restart_ctr := '01'O;
|
||||
/* FIXME: unify with g_bind_ip + parse from config file */
|
||||
var OCT4 g_sgsn_ip_c := '7f172a01'O;
|
||||
|
@ -56,6 +58,11 @@ module GGSN_Tests {
|
|||
}
|
||||
|
||||
function f_init() runs on GT_CT {
|
||||
if (g_initialized == true) {
|
||||
return;
|
||||
}
|
||||
g_initialized := true;
|
||||
|
||||
var Result res;
|
||||
map(self:GTPC, system:GTPC);
|
||||
res := GTP_CodecPort_CtrlFunct.f_IPL4_listen(GTPC, g_bind_ip_c, GTP1C_PORT, {udp:={}});
|
||||
|
|
Loading…
Reference in New Issue