From: ueno Date: Tue, 19 Dec 2006 08:53:17 +0000 (+0000) Subject: Don't specify --armor & --textmode if mode is cleartext X-Git-Tag: epg-0_0_9~19 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0fa019726839e973ca54d429717477fc4ab3276c;p=elisp%2Fepg.git Don't specify --armor & --textmode if mode is cleartext --- diff --git a/epa.el b/epa.el index b9c55d2..de93ed0 100644 --- a/epa.el +++ b/epa.el @@ -809,10 +809,16 @@ d - Create a detached signature (save-excursion (let ((context (epg-make-context)) signature) - ;;(epg-context-set-armor context epa-armor) - (epg-context-set-armor context t) - ;;(epg-context-set-textmode context epa-textmode) - (epg-context-set-textmode context t) + (if (memq mode '(t detached nil normal)) + ;; Normal or detached signature. + (progn + ;;(epg-context-set-armor context epa-armor) + (epg-context-set-armor context t) + ;;(epg-context-set-textmode context epa-textmode) + (epg-context-set-textmode context t)) + ;; Cleartext signature. + (epg-context-set-armor context nil) + (epg-context-set-textmode context nil)) (epg-context-set-signers context signers) (epg-context-set-passphrase-callback context #'epa-passphrase-callback-function)