From f2c503f78701634bd900a7ee47a192e2e945b84f Mon Sep 17 00:00:00 2001 From: kaiw Date: Sun, 24 Feb 2008 18:07:46 +0000 Subject: Since the program is installed as 'bsdranlib', we need to check if it is invoked as 'bsdranlib'. Reported by: Michael Plass Reviewed by: Michael Plass Reviewed by: jkoshy Approved by: jkoshy (mentor) --- usr.bin/ar/ar.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'usr.bin') diff --git a/usr.bin/ar/ar.c b/usr.bin/ar/ar.c index 2399f9f..2eed151 100644 --- a/usr.bin/ar/ar.c +++ b/usr.bin/ar/ar.c @@ -108,7 +108,8 @@ main(int argc, char **argv) if ((bsdar->progname = getprogname()) == NULL) bsdar->progname = "ar"; - if (strcmp(bsdar->progname, "ranlib") == 0) { + if (strcmp(bsdar->progname, "ranlib") == 0 || + strcmp(bsdar->progname, "bsdranlib") == 0) { while ((opt = getopt_long(argc, argv, "tV", longopts, NULL)) != -1) { switch(opt) { -- cgit v1.1