Commit 176f2077 authored by Michael Albinus's avatar Michael Albinus

* net/tramp-sh.el (tramp-get-remote-locale): Return "LC_ALL=C" as

fallback.
(tramp-open-connection-setup-interactive-shell): No need to check
for nil as `tramp-get-remote-locale' return value.
parent d24e558f
2014-11-22 Michael Albinus <michael.albinus@gmx.de>
* net/tramp-sh.el (tramp-get-remote-locale): Return "LC_ALL=C" as
fallback.
(tramp-open-connection-setup-interactive-shell): No need to check
for nil as `tramp-get-remote-locale' return value.
2014-11-21 Eli Zaretskii <eliz@gnu.org>
* vc/vc-git.el (vc-git-command, vc-git--call): Bind
......
......@@ -3972,8 +3972,7 @@ process to set up. VEC specifies the connection."
;; Use MULE to select the right EOL convention for communicating
;; with the process.
(let ((cs (or (and (memq 'utf-8 (coding-system-list))
(string-match
"utf8" (or (tramp-get-remote-locale vec) ""))
(string-match "utf8" (tramp-get-remote-locale vec))
(cons 'utf-8 'utf-8))
(tramp-compat-funcall 'process-coding-system proc)
(cons 'undecided 'undecided)))
......@@ -4080,8 +4079,7 @@ process to set up. VEC specifies the connection."
;; Set the environment.
(tramp-message vec 5 "Setting default environment")
(let ((env (append (when (tramp-get-remote-locale vec) ; Discard `(nil)'.
`(,(tramp-get-remote-locale vec)))
(let ((env (append `(,(tramp-get-remote-locale vec))
(copy-sequence tramp-remote-process-environment)))
unset vars item)
(while env
......@@ -5077,7 +5075,7 @@ Return ATTR."
(defun tramp-get-remote-locale (vec)
(with-tramp-connection-property vec "locale"
(tramp-send-command vec "locale -a")
(let ((candidates '("en_US.utf8" "C.utf8" "C"))
(let ((candidates '("en_US.utf8" "C.utf8"))
locale)
(with-current-buffer (tramp-get-connection-buffer vec)
(while candidates
......@@ -5087,7 +5085,7 @@ Return ATTR."
candidates nil)
(setq candidates (cdr candidates)))))
;; Return value.
(when locale (format "LC_ALL=%s" locale)))))
(format "LC_ALL=%s" (or locale "C")))))
(defun tramp-get-ls-command (vec)
(with-tramp-connection-property vec "ls"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment