aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/tests
diff options
context:
space:
mode:
authorNeels Hofmeyr <nhofmeyr@sysmocom.de>2016-09-16 02:31:17 +0200
committerNeels Hofmeyr <nhofmeyr@sysmocom.de>2016-10-13 13:14:41 +0000
commit4c2d4ab5db5f5703d435e6a49639fca65a049778 (patch)
tree0bd360971fdd49b1bb8550d4d803aba31959977a /openbsc/tests
parente072da9d2e1ea7face8136fa90e6d9e9be70b997 (diff)
msgb talloc ctx: initialize in all main() scopes
Add msgb_talloc_ctx_init() call to many main() functions still lacking a msgb talloc context. Change-Id: Ib0d6751260659cabf18a7ce80680ba2fb4228ea1
Diffstat (limited to 'openbsc/tests')
-rw-r--r--openbsc/tests/bsc-nat/bsc_nat_test.c1
-rw-r--r--openbsc/tests/bsc/bsc_test.c1
-rw-r--r--openbsc/tests/gbproxy/gbproxy_test.c2
-rw-r--r--openbsc/tests/mgcp/mgcp_test.c1
-rw-r--r--openbsc/tests/oap/oap_test.c1
-rw-r--r--openbsc/tests/trau/trau_test.c2
6 files changed, 8 insertions, 0 deletions
diff --git a/openbsc/tests/bsc-nat/bsc_nat_test.c b/openbsc/tests/bsc-nat/bsc_nat_test.c
index b531c6b2d..2914a01b5 100644
--- a/openbsc/tests/bsc-nat/bsc_nat_test.c
+++ b/openbsc/tests/bsc-nat/bsc_nat_test.c
@@ -1551,6 +1551,7 @@ static void test_nat_extract_lac()
int main(int argc, char **argv)
{
+ msgb_talloc_ctx_init(NULL, 0);
sccp_set_log_area(DSCCP);
osmo_init_logging(&log_info);
diff --git a/openbsc/tests/bsc/bsc_test.c b/openbsc/tests/bsc/bsc_test.c
index cc4565246..6d41941c1 100644
--- a/openbsc/tests/bsc/bsc_test.c
+++ b/openbsc/tests/bsc/bsc_test.c
@@ -199,6 +199,7 @@ out:
int main(int argc, char **argv)
{
+ msgb_talloc_ctx_init(NULL, 0);
osmo_init_logging(&log_info);
test_scan();
diff --git a/openbsc/tests/gbproxy/gbproxy_test.c b/openbsc/tests/gbproxy/gbproxy_test.c
index a2ff95b1d..b32ccb5d4 100644
--- a/openbsc/tests/gbproxy/gbproxy_test.c
+++ b/openbsc/tests/gbproxy/gbproxy_test.c
@@ -4842,6 +4842,8 @@ static struct log_info info = {
int main(int argc, char **argv)
{
+ msgb_talloc_ctx_init(NULL, 0);
+
osmo_init_logging(&info);
log_set_use_color(osmo_stderr_target, 0);
log_set_print_filename(osmo_stderr_target, 0);
diff --git a/openbsc/tests/mgcp/mgcp_test.c b/openbsc/tests/mgcp/mgcp_test.c
index 6c94002de..e2dc8fa37 100644
--- a/openbsc/tests/mgcp/mgcp_test.c
+++ b/openbsc/tests/mgcp/mgcp_test.c
@@ -1202,6 +1202,7 @@ static void test_osmux_cid(void)
int main(int argc, char **argv)
{
+ msgb_talloc_ctx_init(NULL, 0);
osmo_init_logging(&log_info);
test_strline();
diff --git a/openbsc/tests/oap/oap_test.c b/openbsc/tests/oap/oap_test.c
index 339d77430..d200ed205 100644
--- a/openbsc/tests/oap/oap_test.c
+++ b/openbsc/tests/oap/oap_test.c
@@ -234,6 +234,7 @@ static struct log_info info = {
int main(int argc, char **argv)
{
+ msgb_talloc_ctx_init(NULL, 0);
osmo_init_logging(&info);
test_oap_api();
diff --git a/openbsc/tests/trau/trau_test.c b/openbsc/tests/trau/trau_test.c
index b95f1e876..c74e6dbb3 100644
--- a/openbsc/tests/trau/trau_test.c
+++ b/openbsc/tests/trau/trau_test.c
@@ -66,6 +66,8 @@ int main()
unsigned char data[33];
int i;
+ msgb_talloc_ctx_init(NULL, 0);
+
memset(data, 0x00, sizeof(data));
test_trau_fr_efr(data);
memset(data, 0xff, sizeof(data));