Change in osmo-mgw[master]: exit(2) on unsupported positional arguments on command line

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
Tue Dec 3 20:51:18 UTC 2019


laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-mgw/+/16448 )


Change subject: exit(2) on unsupported positional arguments on command line
......................................................................

exit(2) on unsupported positional arguments on command line

Change-Id: I5398edac755280d2982285802516681aa5255470
---
M src/osmo-mgw/mgw_main.c
1 file changed, 4 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-mgw refs/changes/48/16448/1

diff --git a/src/osmo-mgw/mgw_main.c b/src/osmo-mgw/mgw_main.c
index adc1751..4168e0d 100644
--- a/src/osmo-mgw/mgw_main.c
+++ b/src/osmo-mgw/mgw_main.c
@@ -132,6 +132,10 @@
 			break;
 		};
 	}
+	if (argc > optind) {
+		fprintf(stderr, "Unsupported positional arguments on command line\n");
+		exit(2);
+	}
 }
 
 /* Callback function to be called when the RSIP ("Reset in Progress") mgcp

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

Gerrit-Project: osmo-mgw
Gerrit-Branch: master
Gerrit-Change-Id: I5398edac755280d2982285802516681aa5255470
Gerrit-Change-Number: 16448
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20191203/91242973/attachment.htm>


More information about the gerrit-log mailing list