pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmo-sigtran/+/41511?usp=email )
Change subject: ss7_as_vty: Forbid configuring RKM-dynamically allocated AS ......................................................................
ss7_as_vty: Forbid configuring RKM-dynamically allocated AS
Change-Id: Ia0c3ce39337de3a10ff0215ccec72c65fab13029 --- M src/ss7_as_vty.c 1 file changed, 5 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-sigtran refs/changes/11/41511/1
diff --git a/src/ss7_as_vty.c b/src/ss7_as_vty.c index 87ea26b..d88c9b4 100644 --- a/src/ss7_as_vty.c +++ b/src/ss7_as_vty.c @@ -71,10 +71,14 @@
as = osmo_ss7_as_find_or_create(inst, name, protocol); if (!as) { - vty_out(vty, "cannot create AS '%s'%s", name, VTY_NEWLINE); + vty_out(vty, "Cannot create AS '%s'%s", name, VTY_NEWLINE); return CMD_WARNING; }
+ if (as->rkm_dyn_allocated) { + vty_out(vty, "Cannot configure RKM-dynamically allocated AS '%s'%s", name, VTY_NEWLINE); + return CMD_WARNING; + }
vty->node = L_CS7_AS_NODE; vty->index = as;