aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVadim Yanitskiy <vyanitskiy@sysmocom.de>2020-09-03 19:19:02 +0700
committerlaforge <laforge@osmocom.org>2020-09-08 20:19:18 +0000
commitccf2017b28af35c6bb1715d2d4b448f97898d1b9 (patch)
treec1e4e0edac4dc129ba931f76b0c25b9c8c581587
parent2eda570b750b5bfda858d5f73d619d5989a26d65 (diff)
vty: propagate result of gsm_bts_set_system_infos()
We should not return CMD_SUCCESS if this functions fails. Change-Id: Id8a761593fe89cc07c2fb6e69558f44494537c47
-rw-r--r--src/osmo-bsc/bsc_vty.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/osmo-bsc/bsc_vty.c b/src/osmo-bsc/bsc_vty.c
index e588ba2e4..352450665 100644
--- a/src/osmo-bsc/bsc_vty.c
+++ b/src/osmo-bsc/bsc_vty.c
@@ -3684,7 +3684,11 @@ DEFUN(cfg_bts_no_acc_ramping, cfg_bts_no_acc_ramping_cmd,
if (acc_ramp_is_enabled(&bts->acc_ramp)) {
acc_ramp_abort(&bts->acc_ramp);
acc_ramp_set_enabled(&bts->acc_ramp, false);
- gsm_bts_set_system_infos(bts);
+ if (gsm_bts_set_system_infos(bts) != 0) {
+ vty_out(vty, "%% Filed to (re)generate System Information "
+ "messages, check the logs%s", VTY_NEWLINE);
+ return CMD_WARNING;
+ }
}
return CMD_SUCCESS;
@@ -4828,7 +4832,11 @@ DEFUN(bts_resend, bts_resend_cmd,
return CMD_WARNING;
}
- gsm_bts_set_system_infos(bts);
+ if (gsm_bts_set_system_infos(bts) != 0) {
+ vty_out(vty, "%% Filed to (re)generate System Information "
+ "messages, check the logs%s", VTY_NEWLINE);
+ return CMD_WARNING;
+ }
return CMD_SUCCESS;
}