From c086d8be130a1c971d6031d0e11f13577e7fd9b9 Mon Sep 17 00:00:00 2001 From: ueno Date: Wed, 7 Mar 2007 23:28:39 +0000 Subject: [PATCH] * epg.el (epg--start): Don't specify --use-agent if the protocol is CMS; set coding-system-for-read to binary. (epg--status-*SIG): Decode user-id. --- ChangeLog | 3 ++- epg.el | 8 ++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 292e2ad..172f898 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,8 @@ 2007-03-07 Daiki Ueno * epg.el (epg--start): Don't specify --use-agent if the protocol - is CMS. + is CMS; set coding-system-for-read to binary. + (epg--status-*SIG): Decode user-id. 2007-02-02 Daiki Ueno diff --git a/epg.el b/epg.el index a9efba4..a3aa5e5 100644 --- a/epg.el +++ b/epg.el @@ -1078,6 +1078,7 @@ This function is for internal use only." (list "--output" (epg-context-output-file context))) args)) (coding-system-for-write 'binary) + (coding-system-for-read 'binary) process-connection-type (orig-mode (default-file-modes)) (buffer (generate-new-buffer " *epg*")) @@ -1318,6 +1319,9 @@ This function is for internal use only." (condition-case nil (setq user-id (epg-dn-from-string user-id)) (error))) + (condition-case nil + (setq user-id (epg--decode-coding-string user-id 'utf-8)) + (error)) (if entry (setcdr entry user-id) (setq epg-user-id-alist @@ -1833,6 +1837,10 @@ You can then use `write-region' to write new data into the file." (defalias 'epg--encode-coding-string 'encode-coding-string) (defalias 'epg--encode-coding-string 'identity)) +(if (fboundp 'decode-coding-string) + (defalias 'epg--decode-coding-string 'decode-coding-string) + (defalias 'epg--decode-coding-string 'identity)) + (defun epg--args-from-sig-notations (notations) (apply #'nconc (mapcar -- 1.7.10.4