Change in osmo-e1d[master]: octoi: Prevent segfault on 'show octoi-clients if a client has no line
laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-e1d/+/29726 ) Change subject: octoi: Prevent segfault on 'show octoi-clients if a client has no line ...................................................................... octoi: Prevent segfault on 'show octoi-clients if a client has no line This can happen if the specified device in the config isn't plugged in for instance, no line is created ... Signed-off-by: Sylvain Munaut <tnt@246tNt.com> Change-Id: I594463591f2945a04ccd708f16788034cc1dfc57 --- M src/octoi/octoi_fsm.c 1 file changed, 4 insertions(+), 2 deletions(-) Approvals: Jenkins Builder: Verified pespin: Looks good to me, but someone else must approve laforge: Looks good to me, approved diff --git a/src/octoi/octoi_fsm.c b/src/octoi/octoi_fsm.c index 39790fa..06d2105 100644 --- a/src/octoi/octoi_fsm.c +++ b/src/octoi/octoi_fsm.c @@ -240,7 +240,9 @@ vty_out(vty, " Peer '%s', Remote "OSMO_SOCKADDR_STR_FMT", State %s%s", peer->name, OSMO_SOCKADDR_STR_FMT_ARGS(&peer->cfg.remote), osmo_fsm_inst_state_name(peer->priv), VTY_NEWLINE); - vty_out_rate_ctr_group(vty, " ", peer->iline->ctrs); - vty_out_stat_item_group(vty, " ", peer->iline->stats); + if (peer->iline) { + vty_out_rate_ctr_group(vty, " ", peer->iline->ctrs); + vty_out_stat_item_group(vty, " ", peer->iline->stats); + } } } -- To view, visit https://gerrit.osmocom.org/c/osmo-e1d/+/29726 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-e1d Gerrit-Branch: master Gerrit-Change-Id: I594463591f2945a04ccd708f16788034cc1dfc57 Gerrit-Change-Number: 29726 Gerrit-PatchSet: 1 Gerrit-Owner: tnt <tnt@246tNt.com> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge@osmocom.org> Gerrit-Reviewer: pespin <pespin@sysmocom.de> Gerrit-MessageType: merged
participants (1)
-
laforge