mirror of
https://gitea.osmocom.org/cellular-infrastructure/osmo-mgw.git
synced 2025-10-23 08:12:01 +00:00
gbproxy_test: Reset the gbproxy before we reset GPRS NS
The peers are (talloc) children of the GPRS NS. This means the peers (and the rate counters) are currently being deleted twice. ==23446== Invalid write of size 4 ==23446== at 0x403C243: rate_ctr_group_alloc (linuxlist.h:66) ==23446== by 0x4050974: gprs_nsvc_create (gprs_ns.c:209) ==23446== by 0x405320D: gprs_ns_instantiate (gprs_ns.c:1330) ==23446== by 0x804ABEB: main (gbproxy_test.c:666) ==23446== Address 0x4300694 is 52 bytes inside a block of size 784 free'd ==23446== at 0x4029DA8: free (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so) ==23446== by 0x4041B9D: _talloc_free (talloc.c:609) ==23446== by 0x4043292: talloc_free (talloc.c:578) ==23446== by 0x40532D3: gprs_ns_destroy (gprs_ns.c:1363) ==23446== by 0x804ABD7: main (gbproxy_test.c:660)
This commit is contained in:
@@ -656,9 +656,9 @@ static void test_gbproxy()
|
|||||||
|
|
||||||
gbprox_dump_global(stdout, 0);
|
gbprox_dump_global(stdout, 0);
|
||||||
|
|
||||||
|
gbprox_reset();
|
||||||
gprs_ns_destroy(nsi);
|
gprs_ns_destroy(nsi);
|
||||||
nsi = NULL;
|
nsi = NULL;
|
||||||
gbprox_reset();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void test_gbproxy_ident_changes()
|
static void test_gbproxy_ident_changes()
|
||||||
@@ -787,9 +787,9 @@ static void test_gbproxy_ident_changes()
|
|||||||
gbprox_dump_global(stdout, 0);
|
gbprox_dump_global(stdout, 0);
|
||||||
gbprox_dump_peers(stdout, 0);
|
gbprox_dump_peers(stdout, 0);
|
||||||
|
|
||||||
|
gbprox_reset();
|
||||||
gprs_ns_destroy(nsi);
|
gprs_ns_destroy(nsi);
|
||||||
nsi = NULL;
|
nsi = NULL;
|
||||||
gbprox_reset();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void test_gbproxy_ra_patching()
|
static void test_gbproxy_ra_patching()
|
||||||
@@ -866,9 +866,9 @@ static void test_gbproxy_ra_patching()
|
|||||||
gbprox_dump_global(stdout, 0);
|
gbprox_dump_global(stdout, 0);
|
||||||
gbprox_dump_peers(stdout, 0);
|
gbprox_dump_peers(stdout, 0);
|
||||||
|
|
||||||
|
gbprox_reset();
|
||||||
gprs_ns_destroy(nsi);
|
gprs_ns_destroy(nsi);
|
||||||
nsi = NULL;
|
nsi = NULL;
|
||||||
gbprox_reset();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user