Commit d381db25 authored by Dominique Quatravaux's avatar Dominique Quatravaux Committed by Michael Albinus
Browse files

Protect environment variables with double quotes in Tramp

* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Protect environment variables with double quotes.

Copyright-paperwork-exempt: yes
parent 0a5898c3
......@@ -4201,10 +4201,11 @@ process to set up. VEC specifies the connection."
(when vars
(tramp-send-command
vec
(format "while read var val; do export $var=$val; done <<'%s'\n%s\n%s"
tramp-end-of-heredoc
(mapconcat 'identity vars "\n")
tramp-end-of-heredoc)
(format
"while read var val; do export $var=\"$val\"; done <<'%s'\n%s\n%s"
tramp-end-of-heredoc
(mapconcat 'identity vars "\n")
tramp-end-of-heredoc)
t))
(when unset
(tramp-send-command
......
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