From 791694856b72c699f8acb53c55a2505f95a3300a Mon Sep 17 00:00:00 2001 From: ueno Date: Thu, 4 Nov 1999 18:16:46 +0000 Subject: [PATCH] * pgg-pgp.el (pgg-pgp-process-region): Set `PGPPASSFD' to 0 before starting PGP process. * pgg-pgp5.el (pgg-pgp5-process-region): Ditto. --- pgg-pgp.el | 3 ++- pgg-pgp5.el | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pgg-pgp.el b/pgg-pgp.el index 1b6f298..dd4cd44 100644 --- a/pgg-pgp.el +++ b/pgg-pgp.el @@ -77,12 +77,13 @@ (with-current-buffer (get-buffer-create output-buffer) (buffer-disable-undo) (erase-buffer)) + (when passphrase + (setenv "PGPPASSFD" "0")) (setq process (apply #'start-process-shell-command "*PGP*" output-buffer program args)) (set-process-sentinel process 'ignore) (when passphrase - (setenv "PGPPASSFD" "0") (process-send-string process (concat passphrase "\n"))) (process-send-region process start end) (process-send-eof process) diff --git a/pgg-pgp5.el b/pgg-pgp5.el index 6e7a920..ad396e3 100644 --- a/pgg-pgp5.el +++ b/pgg-pgp5.el @@ -92,12 +92,13 @@ (with-current-buffer (get-buffer-create output-buffer) (buffer-disable-undo) (erase-buffer)) + (when passphrase + (setenv "PGPPASSFD" "0")) (setq process (apply #'start-process-shell-command "*PGP*" output-buffer program args)) (set-process-sentinel process 'ignore) (when passphrase - (setenv "PGPPASSFD" "0") (process-send-string process (concat passphrase "\n"))) (process-send-region process start end) (process-send-eof process) -- 1.7.10.4