emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master 37c433e4e2: * lisp/net/tramp-gvfs.el (tramp-gvfs-send-command): F


From: Michael Albinus
Subject: master 37c433e4e2: * lisp/net/tramp-gvfs.el (tramp-gvfs-send-command): Fix problem with locale.
Date: Fri, 4 Feb 2022 06:00:11 -0500 (EST)

branch: master
commit 37c433e4e281077488a72eb7a7cc6a33202317ae
Author: Michael Albinus <michael.albinus@gmx.de>
Commit: Michael Albinus <michael.albinus@gmx.de>

    * lisp/net/tramp-gvfs.el (tramp-gvfs-send-command): Fix problem with locale.
---
 lisp/net/tramp-gvfs.el | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/lisp/net/tramp-gvfs.el b/lisp/net/tramp-gvfs.el
index 221ee547a2..763a9e849f 100644
--- a/lisp/net/tramp-gvfs.el
+++ b/lisp/net/tramp-gvfs.el
@@ -2246,13 +2246,7 @@ connection if a previous connection has died for some 
reason."
 COMMAND is a command from the gvfs-* utilities.  It is replaced
 by the corresponding gio tool call if available.  `call-process'
 is applied, and it returns t if the return code is zero."
-  (let* ((locale (tramp-get-local-locale vec))
-        (process-environment
-         (append
-          `(,(format "LANG=%s" locale)
-            ,(format "LANGUAGE=%s" locale)
-            ,(format "LC_ALL=%s" locale))
-          process-environment)))
+  (let ((locale (tramp-get-local-locale vec)))
     (when (tramp-gvfs-gio-tool-p vec)
       ;; Use gio tool.
       (setq args (cons (cdr (assoc command tramp-gvfs-gio-mapping))
@@ -2262,7 +2256,14 @@ is applied, and it returns t if the return code is zero."
     (with-current-buffer (tramp-get-connection-buffer vec)
       (tramp-gvfs-maybe-open-connection vec)
       (erase-buffer)
-      (or (zerop (apply #'tramp-call-process vec command nil t nil args))
+      (or (zerop
+          (apply
+           #'tramp-call-process vec "env" nil t nil
+           (append `(,(format "LANG=%s" locale)
+                     ,(format "LANGUAGE=%s" locale)
+                     ,(format "LC_ALL=%s" locale)
+                     ,command)
+                   args)))
          ;; Remove information about mounted connection.
          (and (tramp-flush-file-properties vec "/") nil)))))
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]