[PATCH] libosmocore[master]: fsm: convenience: add inline osmo_fsm_inst_state_name()

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Tue Feb 28 02:38:51 UTC 2017


Review at  https://gerrit.osmocom.org/1937

fsm: convenience: add inline osmo_fsm_inst_state_name()

Change-Id: If9a6ecc4d6e2beaf716569e9a6053d73488e860b
---
M include/osmocom/core/fsm.h
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/37/1937/1

diff --git a/include/osmocom/core/fsm.h b/include/osmocom/core/fsm.h
index 952f82f..ef8a135 100644
--- a/include/osmocom/core/fsm.h
+++ b/include/osmocom/core/fsm.h
@@ -151,6 +151,8 @@
 const char *osmo_fsm_event_name(struct osmo_fsm *fsm, uint32_t event);
 const char *osmo_fsm_inst_name(struct osmo_fsm_inst *fi);
 const char *osmo_fsm_state_name(struct osmo_fsm *fsm, uint32_t state);
+static inline const char *osmo_fsm_inst_state_name(struct osmo_fsm_inst *fi)
+{ return osmo_fsm_state_name(fi->fsm, fi->state); }
 
 /*! \brief perform a state change of the given FSM instance
  *

-- 
To view, visit https://gerrit.osmocom.org/1937
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: If9a6ecc4d6e2beaf716569e9a6053d73488e860b
Gerrit-PatchSet: 1
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>



More information about the gerrit-log mailing list