[PATCH v1] emacs: `with-current-notmuch-show-message' should not leak `coding-system-for-read'

2014-11-28 Thread David Bremner
David Edmondson  writes:

>  When a message is forwarded, the `no-conversion' coding
> system was applied to the reading of the .signature file, resulting in
> raw rather than UTF-8 interpretation of the data.
> ---
>
> Fix for id:87ioifb55d.fsf at nautilus.nautilus.

pushed

d


Re: [PATCH v1] emacs: `with-current-notmuch-show-message' should not leak `coding-system-for-read'

2014-11-27 Thread David Bremner
David Edmondson d...@dme.org writes:

  When a message is forwarded, the `no-conversion' coding
 system was applied to the reading of the .signature file, resulting in
 raw rather than UTF-8 interpretation of the data.
 ---

 Fix for id:87ioifb55d.fsf@nautilus.nautilus.

pushed

d
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v1] emacs: `with-current-notmuch-show-message' should not leak `coding-system-for-read'

2014-11-19 Thread Tomi Ollila
On Tue, Nov 18 2014, David Edmondson  wrote:

> `with-current-notmuch-show-message' applies a `no-conversion' coding
> system when reading a raw message from notmuch. That coding system
> should _not_ be applied when the body of the macro is evaluated, as it
> can cause file operations used during that evaluation to incorrectly
> apply the `no-conversion' coding system.
>
> This was discovered when a user's .signature file contained non-ASCII
> characters. When a message is forwarded, the `no-conversion' coding
> system was applied to the reading of the .signature file, resulting in
> raw rather than UTF-8 interpretation of the data.
> ---

Uh, this looks as good as it can be ;), and tests pass, +1

Tomi



>
> Fix for id:87ioifb55d.fsf at nautilus.nautilus.
>
>  emacs/notmuch-show.el | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
> index 4035fe8..b8cfbb8 100644
> --- a/emacs/notmuch-show.el
> +++ b/emacs/notmuch-show.el
> @@ -241,9 +241,9 @@ every user interaction with notmuch."
> (let ((buf (generate-new-buffer (concat "*notmuch-msg-" id "*"
>   (with-current-buffer buf
>  (let ((coding-system-for-read 'no-conversion))
> -  (call-process notmuch-command nil t nil "show" "--format=raw" id)
> -  , at body)
> -(kill-buffer buf))
> +  (call-process notmuch-command nil t nil "show" "--format=raw" id))
> +, at body)
> +  (kill-buffer buf)
>  
>  (defun notmuch-show-turn-on-visual-line-mode ()
>"Enable Visual Line mode."
> -- 
> 2.1.3
>
> ___
> notmuch mailing list
> notmuch at notmuchmail.org
> http://notmuchmail.org/mailman/listinfo/notmuch


Re: [PATCH v1] emacs: `with-current-notmuch-show-message' should not leak `coding-system-for-read'

2014-11-19 Thread Tomi Ollila
On Tue, Nov 18 2014, David Edmondson d...@dme.org wrote:

 `with-current-notmuch-show-message' applies a `no-conversion' coding
 system when reading a raw message from notmuch. That coding system
 should _not_ be applied when the body of the macro is evaluated, as it
 can cause file operations used during that evaluation to incorrectly
 apply the `no-conversion' coding system.

 This was discovered when a user's .signature file contained non-ASCII
 characters. When a message is forwarded, the `no-conversion' coding
 system was applied to the reading of the .signature file, resulting in
 raw rather than UTF-8 interpretation of the data.
 ---

Uh, this looks as good as it can be ;), and tests pass, +1

Tomi




 Fix for id:87ioifb55d.fsf@nautilus.nautilus.

  emacs/notmuch-show.el | 6 +++---
  1 file changed, 3 insertions(+), 3 deletions(-)

 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
 index 4035fe8..b8cfbb8 100644
 --- a/emacs/notmuch-show.el
 +++ b/emacs/notmuch-show.el
 @@ -241,9 +241,9 @@ every user interaction with notmuch.
 (let ((buf (generate-new-buffer (concat *notmuch-msg- id *
   (with-current-buffer buf
  (let ((coding-system-for-read 'no-conversion))
 -  (call-process notmuch-command nil t nil show --format=raw id)
 -  ,@body)
 -(kill-buffer buf))
 +  (call-process notmuch-command nil t nil show --format=raw id))
 +,@body)
 +  (kill-buffer buf)
  
  (defun notmuch-show-turn-on-visual-line-mode ()
Enable Visual Line mode.
 -- 
 2.1.3

 ___
 notmuch mailing list
 notmuch@notmuchmail.org
 http://notmuchmail.org/mailman/listinfo/notmuch
___
notmuch mailing list
notmuch@notmuchmail.org
http://notmuchmail.org/mailman/listinfo/notmuch


[PATCH v1] emacs: `with-current-notmuch-show-message' should not leak `coding-system-for-read'

2014-11-18 Thread David Edmondson
`with-current-notmuch-show-message' applies a `no-conversion' coding
system when reading a raw message from notmuch. That coding system
should _not_ be applied when the body of the macro is evaluated, as it
can cause file operations used during that evaluation to incorrectly
apply the `no-conversion' coding system.

This was discovered when a user's .signature file contained non-ASCII
characters. When a message is forwarded, the `no-conversion' coding
system was applied to the reading of the .signature file, resulting in
raw rather than UTF-8 interpretation of the data.
---

Fix for id:87ioifb55d.fsf at nautilus.nautilus.

 emacs/notmuch-show.el | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index 4035fe8..b8cfbb8 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -241,9 +241,9 @@ every user interaction with notmuch."
(let ((buf (generate-new-buffer (concat "*notmuch-msg-" id "*"
  (with-current-buffer buf
   (let ((coding-system-for-read 'no-conversion))
-(call-process notmuch-command nil t nil "show" "--format=raw" id)
-, at body)
-  (kill-buffer buf))
+(call-process notmuch-command nil t nil "show" "--format=raw" id))
+  , at body)
+(kill-buffer buf)

 (defun notmuch-show-turn-on-visual-line-mode ()
   "Enable Visual Line mode."
-- 
2.1.3