libosmocore/include/osmocom/core
Neels Hofmeyr c014f606d0 fsm: factor out osmo_fsm_inst_term_children() from osmo_fsm_inst_term()
osmo_fsm_inst_term() has code for safe child removal, publish that part as
osmo_fsm_inst_term_children(); also use from osmo_fsm_inst_term().

As with osmo_fsm_inst_term(), add osmo_fsm_inst_term_children() macro to pass
the caller's source file and line to new _osmo_fsm_inst_term_children().

Rationale: in openbsc's VLR, I want to discard child FSMs when certain events
are handled. I could keep a pointer to each one, or simply iterate all
children, making the code a lot simpler in some places.

(Unfortunately, the patch may be displayed subobtimally. This really only moves
the children-loop to a new function, replaces it with a call to
_osmo_fsm_inst_term_children(fi, OSMO_FSM_TERM_PARENT, NULL, file, line) and
drops two local iterator variables. No other code changes are made, even though
the diff may show large removal + addition chunks)

Change-Id: I8dac1206259cbd251660f793ad023aaa1dc705a2
2016-12-24 17:11:52 +00:00
..
application.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
backtrace.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
bitXXgen.h.tpl comments 2015-10-09 00:01:06 +02:00
bitcomp.h bitcomp: Remove the t4 decoding from libosmocore 2016-11-10 17:07:45 +00:00
bits.h Add octet-aligned/unaligned shift functions 2016-06-20 19:02:56 +02:00
bitvec.h Mark input parameter to bitvec_set_bits() as 'const' 2016-06-27 15:19:10 +02:00
conv.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
crc16.h add CRC16-CCITT to libosmocore 2016-12-23 22:16:08 +01:00
crcXXgen.h.tpl include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
crcgen.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
defs.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
endian.h Fixing build on Mac OSX 2016-05-28 16:59:56 +00:00
fsm.h fsm: factor out osmo_fsm_inst_term_children() from osmo_fsm_inst_term() 2016-12-24 17:11:52 +00:00
gsmtap.h gsmtap: Add defintions for GSMTAP based remote logging 2016-12-09 17:59:58 +01:00
gsmtap_util.h Update doxygen annotations in libosmocore 2016-05-05 18:49:27 +02:00
linuxlist.h Update doxygen annotations in libosmocore 2016-05-05 18:49:27 +02:00
linuxrbtree.h fix FSF address in sources/headers 2015-11-12 13:46:05 +01:00
logging.h fsm: log caller's source for events and state changes, not fsm.c lines 2016-12-14 18:00:52 +01:00
loggingrb.h sttrb / loggingrb: Use GPLv2+ as license, not AGPLv3+ 2014-10-26 20:52:25 +01:00
macaddr.h Convert recently-introduced header files to #pragma once 2014-08-21 15:42:44 +02:00
msgb.h msgb: add msgb_push_u{8,16,32}() functions 2016-11-11 19:28:32 +01:00
msgfile.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
panic.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
plugin.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
prim.h comment typo 2016-01-18 10:44:36 +01:00
process.h merge process.[ch] with application.[ch] 2011-06-26 14:14:05 +02:00
rate_ctr.h Update doxygen annotations in libosmocore 2016-05-05 18:49:27 +02:00
select.h select: Externalize fd_set filling and dispatch 2016-03-31 16:56:51 +02:00
serial.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
signal.h Update doxygen annotations in libosmocore 2016-05-05 18:49:27 +02:00
socket.h Update doxygen annotations in libosmocore 2016-05-05 18:49:27 +02:00
stat_item.h stats: Add OSMO prefix to STAT_ITEM_NOVALUE_ID 2015-12-08 10:33:15 +01:00
statistics.h core/counter: add osmo_counter_dec() 2016-08-30 12:02:58 +02:00
stats.h statsd: Fix compiler warning (int32_t vs. int64_t) 2016-11-11 15:24:24 +01:00
strrb.h sttrb / loggingrb: Use GPLv2+ as license, not AGPLv3+ 2014-10-26 20:52:25 +01:00
talloc.h remove our internal copy of talloc, use system libtalloc 2015-12-05 23:38:18 +01:00
timer.h add osmo_gettimeofday as a shim around gettimeofday 2016-09-22 07:18:39 +02:00
timer_compat.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00
utils.h utils.h: add OSMO_STRINGIFY and OSMO_VALUE_STRING macros 2016-12-21 10:37:13 +00:00
write_queue.h include: Switch to #pragma once pattern 2014-06-16 10:17:27 +02:00