Change in osmo-ggsn[master]: vty: Inform user that static IP addresses are not supported

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/.

laforge gerrit-no-reply at lists.osmocom.org
Mon Mar 29 08:21:27 UTC 2021


laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/23517 )

Change subject: vty: Inform user that static IP addresses are not supported
......................................................................

vty: Inform user that static IP addresses are not supported

Currently, osmo-ggsn doesn't implement PDP contexts with static IP
addresses.  The code for specifying ranges that can be used for
static IPs was always present even from OpenGGSN days, but we never
really treated them.  Let's not raise the impression we do by
warning accordingly if the user configures them.

Change-Id: I7787dae037c46c0c5052aa6dd000be330984f144
Related: OS#5097
---
M ggsn/ggsn_vty.c
1 file changed, 8 insertions(+), 4 deletions(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, approved



diff --git a/ggsn/ggsn_vty.c b/ggsn/ggsn_vty.c
index 71d8ff6..1738e70 100644
--- a/ggsn/ggsn_vty.c
+++ b/ggsn/ggsn_vty.c
@@ -533,9 +533,11 @@
 	struct in46_prefix *pfx;
 
 	/* first update our parsed prefix */
-	if (!strcmp(argv[0], "static"))
+	if (!strcmp(argv[0], "static")) {
 		pfx = &apn->v4.cfg.static_prefix;
-	else
+		vty_out(vty, "%% static IP addresses currently not yet supported%s", VTY_NEWLINE);
+		return CMD_WARNING;
+	} else
 		pfx = &apn->v4.cfg.dynamic_prefix;
 	str2prefix(pfx, argv[1]);
 
@@ -567,9 +569,11 @@
 	struct apn_ctx *apn = (struct apn_ctx *) vty->index;
 	struct in46_prefix *pfx;
 
-	if (!strcmp(argv[0], "static"))
+	if (!strcmp(argv[0], "static")) {
 		pfx = &apn->v6.cfg.static_prefix;
-	else
+		vty_out(vty, "%% static IP addresses currently not yet supported%s", VTY_NEWLINE);
+		return CMD_WARNING;
+	} else
 		pfx = &apn->v6.cfg.dynamic_prefix;
 	str2prefix(pfx, argv[1]);
 	return CMD_SUCCESS;

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-ggsn/+/23517
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I7787dae037c46c0c5052aa6dd000be330984f144
Gerrit-Change-Number: 23517
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210329/20cd9f08/attachment.htm>


More information about the gerrit-log mailing list