Mercurial > emacs
comparison lisp/international/mule-cmds.el @ 49042:01956f552316
(set-locale-environment): Ignore
empty values of environment variables.
author | Dave Love <fx@gnu.org> |
---|---|
date | Sun, 05 Jan 2003 00:38:05 +0000 |
parents | 835ac7993b8d |
children | f7c2ae4decd6 |
comparison
equal
deleted
inserted
replaced
49041:55904f644d2a | 49042:01956f552316 |
---|---|
2185 | 2185 |
2186 (unless locale | 2186 (unless locale |
2187 ;; Use the first of these three environment variables | 2187 ;; Use the first of these three environment variables |
2188 ;; that has a nonempty value. | 2188 ;; that has a nonempty value. |
2189 (let ((vars '("LC_ALL" "LC_CTYPE" "LANG"))) | 2189 (let ((vars '("LC_ALL" "LC_CTYPE" "LANG"))) |
2190 (while (and vars (not (setq locale (getenv (car vars))))) | 2190 (while (and vars |
2191 (setq vars (cdr vars))))) | 2191 (= 0 (length locale))) ; nil or empty string |
2192 (setq locale (getenv (pop vars)))))) | |
2192 | 2193 |
2193 (when locale | 2194 (when locale |
2194 | 2195 |
2195 ;; Translate "swedish" into "sv_SE.ISO8859-1", and so on, | 2196 ;; Translate "swedish" into "sv_SE.ISO8859-1", and so on, |
2196 ;; using the translation file that many systems have. | 2197 ;; using the translation file that many systems have. |