aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Schwab2012-12-28 10:49:59 +0100
committerAndreas Schwab2012-12-28 10:49:59 +0100
commit361828b5dbb00fc562c3349870cc29e5ea354f4d (patch)
treeeb706b93d93e9e9222919986281970d3e7886653
parent23bd348c3f3c848957088950df797d49794f7667 (diff)
downloademacs-361828b5dbb00fc562c3349870cc29e5ea354f4d.tar.gz
emacs-361828b5dbb00fc562c3349870cc29e5ea354f4d.zip
* epg.el (epg--start): Modify process-environment locally.
-rw-r--r--lisp/ChangeLog4
-rw-r--r--lisp/epg.el6
2 files changed, 8 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index c4d884a5010..e13ce397bee 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,7 @@
12012-12-28 Andreas Schwab <schwab@linux-m68k.org>
2
3 * epg.el (epg--start): Modify process-environment locally.
4
12012-12-28 Daiki Ueno <ueno@gnu.org> 52012-12-28 Daiki Ueno <ueno@gnu.org>
2 6
3 * epg.el: Support pinentry-curses. 7 * epg.el: Support pinentry-curses.
diff --git a/lisp/epg.el b/lisp/epg.el
index 5fb8f809aa9..a1bc25e1c44 100644
--- a/lisp/epg.el
+++ b/lisp/epg.el
@@ -1156,6 +1156,7 @@ This function is for internal use only."
1156 (coding-system-for-write 'binary) 1156 (coding-system-for-write 'binary)
1157 (coding-system-for-read 'binary) 1157 (coding-system-for-read 'binary)
1158 process-connection-type 1158 process-connection-type
1159 (process-environment process-environment)
1159 (orig-mode (default-file-modes)) 1160 (orig-mode (default-file-modes))
1160 (buffer (generate-new-buffer " *epg*")) 1161 (buffer (generate-new-buffer " *epg*"))
1161 process 1162 process
@@ -1170,8 +1171,9 @@ This function is for internal use only."
1170 (delete-backward-char 1) 1171 (delete-backward-char 1)
1171 (setq terminal-name (buffer-string)))) 1172 (setq terminal-name (buffer-string))))
1172 (when terminal-name 1173 (when terminal-name
1173 (setenv "GPG_TTY" terminal-name) 1174 (setq process-environment
1174 (setenv "TERM" "xterm")) 1175 (cons (concat "GPG_TTY=" terminal-name)
1176 (cons "TERM=xterm" process-environment))))
1175 ;; Record modified time of gpg-agent socket to restore the Emacs 1177 ;; Record modified time of gpg-agent socket to restore the Emacs
1176 ;; frame on text terminal in `epg-wait-for-completion'. 1178 ;; frame on text terminal in `epg-wait-for-completion'.
1177 ;; See 1179 ;; See