[MERGED] osmo-trx[master]: use osmo_init_logging2()
Harald Welte has submitted this change and it was merged. Change subject: use osmo_init_logging2() .. use osmo_init_logging2() Change-Id: I2c28e6e6e3eb9f587680b34330e03408e32c2b94 --- M Transceiver52M/osmo-trx.cpp M tests/CommonLibs/LogTest.cpp 2 files changed, 7 insertions(+), 2 deletions(-) Approvals: Harald Welte: Looks good to me, approved Jenkins Builder: Verified diff --git a/Transceiver52M/osmo-trx.cpp b/Transceiver52M/osmo-trx.cpp index 2eb8309..1b351d6 100644 --- a/Transceiver52M/osmo-trx.cpp +++ b/Transceiver52M/osmo-trx.cpp @@ -506,7 +506,7 @@ convolve_init(); convert_init(); - osmo_init_logging(&log_info); + osmo_init_logging2(tall_trx_ctx, &log_info); osmo_stats_init(tall_trx_ctx); vty_init(&g_vty_info); ctrl_vty_init(tall_trx_ctx); diff --git a/tests/CommonLibs/LogTest.cpp b/tests/CommonLibs/LogTest.cpp index b8677e6..5167a62 100644 --- a/tests/CommonLibs/LogTest.cpp +++ b/tests/CommonLibs/LogTest.cpp @@ -29,6 +29,8 @@ #include "Logger.h" extern "C" { +#include +#include #include #include #include "debug.h" @@ -50,7 +52,10 @@ linfo.cat = categories; linfo.num_cat = ARRAY_SIZE(categories); - osmo_init_logging(&linfo); + void *tall_ctx = talloc_named_const(NULL, 1, "OsmoTRX context"); + msgb_talloc_ctx_init(tall_ctx, 0); + + osmo_init_logging2(tall_ctx, &linfo); log_set_use_color(osmo_stderr_target, 0); log_set_print_filename(osmo_stderr_target, 0); -- To view, visit https://gerrit.osmocom.org/7827 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I2c28e6e6e3eb9f587680b34330e03408e32c2b94 Gerrit-PatchSet: 1 Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Owner: Pau Espin Pedrol Gerrit-Reviewer: Harald Welte Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Neels Hofmeyr
osmo-trx[master]: use osmo_init_logging2()
Patch Set 1: Code-Review+2 -- To view, visit https://gerrit.osmocom.org/7827 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I2c28e6e6e3eb9f587680b34330e03408e32c2b94 Gerrit-PatchSet: 1 Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Owner: Pau Espin Pedrol Gerrit-Reviewer: Harald Welte Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Neels Hofmeyr Gerrit-HasComments: No
[PATCH] osmo-trx[master]: use osmo_init_logging2()
Review at https://gerrit.osmocom.org/7827 use osmo_init_logging2() Change-Id: I2c28e6e6e3eb9f587680b34330e03408e32c2b94 --- M Transceiver52M/osmo-trx.cpp M tests/CommonLibs/LogTest.cpp 2 files changed, 7 insertions(+), 2 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/27/7827/1 diff --git a/Transceiver52M/osmo-trx.cpp b/Transceiver52M/osmo-trx.cpp index 2eb8309..1b351d6 100644 --- a/Transceiver52M/osmo-trx.cpp +++ b/Transceiver52M/osmo-trx.cpp @@ -506,7 +506,7 @@ convolve_init(); convert_init(); - osmo_init_logging(&log_info); + osmo_init_logging2(tall_trx_ctx, &log_info); osmo_stats_init(tall_trx_ctx); vty_init(&g_vty_info); ctrl_vty_init(tall_trx_ctx); diff --git a/tests/CommonLibs/LogTest.cpp b/tests/CommonLibs/LogTest.cpp index b8677e6..5167a62 100644 --- a/tests/CommonLibs/LogTest.cpp +++ b/tests/CommonLibs/LogTest.cpp @@ -29,6 +29,8 @@ #include "Logger.h" extern "C" { +#include +#include #include #include #include "debug.h" @@ -50,7 +52,10 @@ linfo.cat = categories; linfo.num_cat = ARRAY_SIZE(categories); - osmo_init_logging(&linfo); + void *tall_ctx = talloc_named_const(NULL, 1, "OsmoTRX context"); + msgb_talloc_ctx_init(tall_ctx, 0); + + osmo_init_logging2(tall_ctx, &linfo); log_set_use_color(osmo_stderr_target, 0); log_set_print_filename(osmo_stderr_target, 0); -- To view, visit https://gerrit.osmocom.org/7827 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I2c28e6e6e3eb9f587680b34330e03408e32c2b94 Gerrit-PatchSet: 1 Gerrit-Project: osmo-trx Gerrit-Branch: master Gerrit-Owner: Pau Espin Pedrol