aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-04-30 11:08:22 +0800
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-04-30 11:08:22 +0800
commit37ba5b3e356d7ad15a61dcc41206f9a944ebc82f (patch)
treea146d40d5adc65312e4ea656e3c507b97b92ce18
parent9f63d2b4ad4a8eccbbbd49abb5f69d1b10571433 (diff)
nat: Report some more contexts
-rw-r--r--openbsc/src/nat/bsc_nat.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/openbsc/src/nat/bsc_nat.c b/openbsc/src/nat/bsc_nat.c
index 842bb0a2..bf015329 100644
--- a/openbsc/src/nat/bsc_nat.c
+++ b/openbsc/src/nat/bsc_nat.c
@@ -815,10 +815,20 @@ static void signal_handler(int signal)
}
}
+extern void *tall_msgb_ctx;
+extern void *tall_ctr_ctx;
+static void talloc_init_ctx()
+{
+ tall_bsc_ctx = talloc_named_const(NULL, 0, "nat");
+ tall_msgb_ctx = talloc_named_const(tall_bsc_ctx, 0, "msgb");
+ tall_ctr_ctx = talloc_named_const(tall_bsc_ctx, 0, "counter");
+}
+
int main(int argc, char** argv)
{
+ talloc_init_ctx();
log_init(&log_info);
- tall_bsc_ctx = talloc_named_const(NULL, 1, "nat");
+
stderr_target = log_target_create_stderr();
log_add_target(stderr_target);
log_set_all_filter(stderr_target, 1);