From baf58b562274f5ceec9b8d62f9d4557abd5776dc Mon Sep 17 00:00:00 2001 From: "Andrey A. Chernov" Date: Sun, 10 Jun 2001 23:42:31 +0000 Subject: [PATCH] In debug mode don't print error for C,POSIX,ASCII,US-ASCII locales --- gnu/usr.bin/man/man/man.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/gnu/usr.bin/man/man/man.c b/gnu/usr.bin/man/man/man.c index 7c9481cb10b..8edb48c86db 100644 --- a/gnu/usr.bin/man/man/man.c +++ b/gnu/usr.bin/man/man/man.c @@ -467,8 +467,13 @@ man_getopt (argc, argv) || strlen(tmp + 1) < 4 || tmp[3] != '.') { if (debug) { - errno = EINVAL; - perror ("ctype locale env"); + if (strcmp(locale, "C") != 0 && + strcmp(locale, "POSIX") != 0 && + strcmp(locale, "ASCII") != 0 && + strcmp(locale, "US-ASCII") != 0) { + errno = EINVAL; + perror ("ctype locale env"); + } } locale = NULL; } else {