aboutsummaryrefslogtreecommitdiff
path: root/gnu/usr.bin/man/makewhatis/makewhatis.perl
diff options
context:
space:
mode:
authorRuslan Ermilov <ru@FreeBSD.org>2001-03-02 16:52:14 +0000
committerRuslan Ermilov <ru@FreeBSD.org>2001-03-02 16:52:14 +0000
commitafcf05e46aacbe58f9fd8338ab6ecf9b7d06d004 (patch)
tree4d1655d724be575f060459c555ab30a5630ec3e9 /gnu/usr.bin/man/makewhatis/makewhatis.perl
parent7a6be913664526370f69f43e340b7ed33f20ea8f (diff)
downloadsrc-afcf05e46aacbe58f9fd8338ab6ecf9b7d06d004.tar.gz
src-afcf05e46aacbe58f9fd8338ab6ecf9b7d06d004.zip
setlocale(3) has been fixed to match POSIX standard:
LC_ALL takes precedence over other LC_* envariables.
Notes
Notes: svn path=/head/; revision=73349
Diffstat (limited to 'gnu/usr.bin/man/makewhatis/makewhatis.perl')
-rw-r--r--gnu/usr.bin/man/makewhatis/makewhatis.perl10
1 files changed, 2 insertions, 8 deletions
diff --git a/gnu/usr.bin/man/makewhatis/makewhatis.perl b/gnu/usr.bin/man/makewhatis/makewhatis.perl
index 2080aa5b0a64..4a4ab4465464 100644
--- a/gnu/usr.bin/man/makewhatis/makewhatis.perl
+++ b/gnu/usr.bin/man/makewhatis/makewhatis.perl
@@ -433,14 +433,8 @@ sub variables {
$append = 0; # Don't delete old entries
$locale = 0; # Build DB only for localized man directories
- # choose localized man direcotries suffixs. If $LC_CTYPE is set, then
- # its value will be used as suffix, otherwise $LANG value (if set)
- $local_suffix = "";
- if ($ENV{'LC_CTYPE'}) {
- $local_suffix = $ENV{'LC_CTYPE'};
- } elsif ($ENV{'LANG'}) {
- $local_suffix = $ENV{'LANG'}
- }
+ # choose localized man directories suffix.
+ $local_suffix = $ENV{'LC_ALL'} || $ENV{'LC_CTYPE'} || $ENV{'LANG'};
# if no argument for directories given
@defaultmanpath = ( '/usr/share/man' );