From 9803a35a8a3332f32f1dd2e9cd5c5e591a31b095 Mon Sep 17 00:00:00 2001 From: Vadim Yanitskiy Date: Sun, 8 Apr 2018 17:41:25 +0700 Subject: host/trxcon: track talloc NULL contexts by default In order to be able to introspect not only the root application context, but also all other contexts, e.g. allocated within libosmocore or other libraries, let's enable tracking the use of NULL contexts using the corresponding talloc API. Change-Id: Id21cd5ee340def443f7a5d0b2b8f37f41188dd87 --- src/host/trxcon/trxcon.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/host/trxcon/trxcon.c b/src/host/trxcon/trxcon.c index 1d0ecc3a..c7468169 100644 --- a/src/host/trxcon/trxcon.c +++ b/src/host/trxcon/trxcon.c @@ -247,6 +247,9 @@ int main(int argc, char **argv) init_defaults(); handle_options(argc, argv); + /* Track the use of talloc NULL memory contexts */ + talloc_enable_null_tracking(); + /* Init talloc memory management system */ tall_trx_ctx = talloc_init("trxcon context"); msgb_talloc_ctx_init(tall_trx_ctx, 0); -- cgit v1.2.3