diff options
author | Pau Espin Pedrol <pespin@sysmocom.de> | 2018-08-16 19:05:19 +0200 |
---|---|---|
committer | Pau Espin Pedrol <pespin@sysmocom.de> | 2018-08-16 21:03:32 +0200 |
commit | 0b6fcb0349a608023d971d576fe2ee6af18dcb45 (patch) | |
tree | faf63605c9cfb3eb45b43233aa2c38a7003de251 /include/osmocom/core/signal.h | |
parent | acc0a070c770eb16aba8ef93780eda5365057b6c (diff) |
signal: Introduce API osmo_signal_talloc_ctx_init
Otherwise applications need to use "extern void* tall_sigh_ctx" and set
it manually (that symbol is not exported in any header file) or end up
allocating struct signal_handler into the NULL talloc ctx.
API created in a similar way as already existing msgb_talloc_ctx_init(),
but without the pool_size because it's not considered necessary in this
case.
Change-Id: Id58ca18eb826b8f4183a7cf0dbb2b38cba702a09
Diffstat (limited to 'include/osmocom/core/signal.h')
-rw-r--r-- | include/osmocom/core/signal.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/osmocom/core/signal.h b/include/osmocom/core/signal.h index ae78f152..449b9762 100644 --- a/include/osmocom/core/signal.h +++ b/include/osmocom/core/signal.h @@ -34,6 +34,7 @@ typedef int osmo_signal_cbfn(unsigned int subsys, unsigned int signal, void *han /* Management */ +void *osmo_signal_talloc_ctx_init(void *root_ctx); int osmo_signal_register_handler(unsigned int subsys, osmo_signal_cbfn *cbfn, void *data); void osmo_signal_unregister_handler(unsigned int subsys, osmo_signal_cbfn *cbfn, void *data); |