Change in ...osmo-ggsn[master]: sgsnemu: Fix format string argument count

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
Sun Jul 21 10:37:03 UTC 2019


laforge has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ggsn/+/14878


Change subject: sgsnemu: Fix format string argument count
......................................................................

sgsnemu: Fix format string argument count

Change-Id: I6bb8c3df53a585913d5e0351ecad2e6ae9f0b886
Closes: CID#178643
---
M sgsnemu/sgsnemu.c
1 file changed, 8 insertions(+), 4 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-ggsn refs/changes/78/14878/1

diff --git a/sgsnemu/sgsnemu.c b/sgsnemu/sgsnemu.c
index 36b52fc..8e41031 100644
--- a/sgsnemu/sgsnemu.c
+++ b/sgsnemu/sgsnemu.c
@@ -1452,12 +1452,16 @@
 		if (!accept_ra || !forwarding)
 			printf("Could not open proc file for %s ?!?\n", tun->devname);
 		else {
-			if (!strcmp(accept_ra, "0") ||
-			    (!strcmp(forwarding, "1") && !strcmp(accept_ra, "1"))) {
-				printf("%s is %s, i.e. your tun device is not configured to accept "
-					"router advertisements; SLAAC will not suceed, please "
+			if (!strcmp(accept_ra, "0")) {
+				printf("accept_ra=0, i.e. your tun device is not configured to accept "
+					"router advertisements; SLAAC will not succeed, please "
 					"fix your setup!\n");
 			}
+			if (!strcmp(forwarding, "1") && !strcmp(accept_ra, "1")) {
+				printf("forwarding=1 and accept_ra=1, i.e. your tun device is not "
+					"configured to accept router advertisements; SLAAC will not "
+					"succeed, please fix your setup!\n");
+			}
 		}
 		free(accept_ra);
 		free(forwarding);

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

Gerrit-Project: osmo-ggsn
Gerrit-Branch: master
Gerrit-Change-Id: I6bb8c3df53a585913d5e0351ecad2e6ae9f0b886
Gerrit-Change-Number: 14878
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge at gnumonks.org>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190721/a90fdfb9/attachment.htm>


More information about the gerrit-log mailing list