From 948453970e588ce0752772fa3a37b099b55001e3 Mon Sep 17 00:00:00 2001
From: dd
Date: Fri, 13 Jul 2001 14:10:09 +0000
Subject: [PATCH] Whine if we discover an unknown option. This program doesn't
use getopt(3) (and can't be converted without breaking compatibility), and
it's very irritating to have it silently DTWT if one combines options
together (e.g., "-msS domain,server").
---
usr.sbin/ypbind/ypbind.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/usr.sbin/ypbind/ypbind.c b/usr.sbin/ypbind/ypbind.c
index e178f6ad306f..bdc3aa4e9177 100644
--- a/usr.sbin/ypbind/ypbind.c
+++ b/usr.sbin/ypbind/ypbind.c
@@ -419,6 +419,8 @@ char **argv;
yp_restricted_mode(argv[i+1]);
else if (strcmp("-m", argv[i]) == 0)
yp_manycast++;
+ else
+ errx(1, "unknown option: %s", argv[i]);
}
/* blow away everything in BINDINGDIR (if it exists) */