Your message dated Tue, 01 Apr 2014 12:18:56 +0000
with message-id <[email protected]>
and subject line Bug#742206: fixed in wl-beta 2.15.9+0.20130701-7
has caused the Debian Bug report #742206,
regarding elmo stores messages incorrectly with inhibit-eol-conversion set
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
742206: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=742206
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: wl-beta
Version: 2.15.9+0.20130701-6
Severity: important
Tags: patch

The patch 10_ikazuhiro.patch in -6 makes the following change in
elmo-util.el:

 (defsubst elmo-delete-cr-region (start end)
   "Delete CR from region."
-  (save-excursion
-    (goto-char start)
-    (while (search-forward "\r\n" end t)
-      (replace-match "\n")) ))
+  (decode-coding-region start (or end (point-max)) 'raw-text-dos))

And later:

 (defun elmo-delete-cr (string)
-  (save-match-data
-    (elmo-set-work-buf
-      (insert string)
-      (goto-char (point-min))
-      (while (search-forward "\r\n" nil t)
-       (replace-match "\n"))
-      (buffer-string))))
+  (decode-coding-string string 'raw-text-dos))

This is problematic because decode-coding-{region,string} won't strip
CRs with raw-text-dos unless inhibit-eol-conversion is nil (see
decode_coding_raw_text() in coding.c).  And this variable is documented
in the manual as a preference and may well have been changed from the
default nil:

  Emacs recognizes which kind of end-of-line conversion to use based on
  the contents of the file: if it sees only carriage-returns, or only
  carriage-return linefeed sequences, then it chooses the end-of-line
  conversion accordingly.  You can inhibit the automatic use of
  end-of-line conversion by setting the variable `inhibit-eol-conversion'
  to non-`nil'.  If you do that, DOS-style files will be displayed with
  the `^M' characters visible in the buffer; some people prefer this to
  the more subtle `(DOS)' end-of-line type indication near the left edge
  of the mode line (*note eol-mnemonic: Mode Line.).

So now, if inhibit-eol-conversion is non-nil, elmo will cache the
message with the CRs and various things that parse the stored message
using regexps and expect headers to end in LFs will break.  (I first
noticed this when mmbuffer-parse-multipart in flim/mmbuffer.el started
producing message/x-broken messages).

The fix seems trivial:

(defsubst elmo-delete-cr-region (start end)
  "Delete CR from region."
  (let ((inhibit-eol-conversion nil))
    (decode-coding-region start (or end (point-max)) 'raw-text-dos)))

(defun elmo-delete-cr (string)
  (let ((inhibit-eol-conversion nil))
    (decode-coding-string string 'raw-text-dos)))


Thanks,

-- 
Stelios.

--- End Message ---
--- Begin Message ---
Source: wl-beta
Source-Version: 2.15.9+0.20130701-7

We believe that the bug you reported is fixed in the latest version of
wl-beta, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Tatsuya Kinoshita <[email protected]> (supplier of updated wl-beta package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Tue, 01 Apr 2014 20:44:40 +0900
Source: wl-beta
Binary: wl-beta
Architecture: source all
Version: 2.15.9+0.20130701-7
Distribution: unstable
Urgency: medium
Maintainer: Tatsuya Kinoshita <[email protected]>
Changed-By: Tatsuya Kinoshita <[email protected]>
Description: 
 wl-beta    - mail/news reader supporting IMAP for emacsen (development version
Closes: 742206
Changes: 
 wl-beta (2.15.9+0.20130701-7) unstable; urgency=medium
 .
   * Sync 10_ikazuhiro.patch on 2014-03-31 to fix elmo-util (closes: #742206)
Checksums-Sha1: 
 620ec4e196c2c3d308fb67d70ecbcdaab438e4af 1991 wl-beta_2.15.9+0.20130701-7.dsc
 8939a232dd3d4912ff4db0c1167955df09c5b666 23608 
wl-beta_2.15.9+0.20130701-7.debian.tar.xz
 8562fa8ab1a49f1c52062f9cb1f49ff3e1def1d2 779602 
wl-beta_2.15.9+0.20130701-7_all.deb
Checksums-Sha256: 
 8b770c57549909ab8e5d529977f6c82009ba5e757674bd7ff88af09c1b2f169d 1991 
wl-beta_2.15.9+0.20130701-7.dsc
 4e194972ded7c03b4f77a32d04469938cc15a4df3e3f44531e98e85f07193fed 23608 
wl-beta_2.15.9+0.20130701-7.debian.tar.xz
 81fbef046bd8aeb9add759bf01f2f78e9f4fa3be69d27ba3418c654a8340459c 779602 
wl-beta_2.15.9+0.20130701-7_all.deb
Files: 
 fe717ae5cea82db03d509ef448388bdb 1991 lisp extra 
wl-beta_2.15.9+0.20130701-7.dsc
 5b89dcffe83b1396dbc3df9f06578dbc 23608 lisp extra 
wl-beta_2.15.9+0.20130701-7.debian.tar.xz
 0bdfce2371af8ad25bdbda694a5d7bbd 779602 lisp extra 
wl-beta_2.15.9+0.20130701-7_all.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJTOqm9AAoJEOXvq5AIDqY8BvwP/iIEvS7x70cXeB4/4jYGdbE/
Sqn+iz/a/cnqq2T4pZbgynxWtHApp5Pb9kSpAmAJF2+4dgOvuXJfsqr3OBcG+sQg
5WRSpr2U6ULeVYDFSkec5ec0NgT14iskF3yqDK2DIM+UJJnQ/jbSdNPcRuv7lDQ9
CUxEHJNCi1x+N1wMkhW5BgK7U3mnFGiDlmAqc3KnmqzwXSsZ3rpq0SeZN9/hSykt
yzHS3N/H/VrPL58Nj62sFUmuxb0TyGHdfKt5gABAAtPI2UUOpCIETqtAGOakU7jk
SSyE9WHh9ov98JAOrvPclc5+S5TgR0EcIWpw6QA40/tFKVnxCXkUrMFp+daRlgR5
EgZ0qQpXK8qQPs7w7e5Rk8A253VJrXKH9xZdlveWeNsCKKASoHrdNsdD1pF+6YFe
ysDbeT2wiQwyTRCqHBLdKelopeFaELHz2mRnMWq7AoT6CRj67ZFu9kLaKyIJNN2e
gE49wyfO6tVzPUt5OimNVy/UPJQrDB9hzE813WLS9UG8yZ2YoXL0oy9lbxoaWCYh
fREAiglYVSX6oSb+juL60Uq9zV8QKE/tIXKbG0rk4Mbz2qTIMkOOIZ93RcQ70dAQ
3HBP/4d0mrOLSnItEqowQy7u5kvnlB/9ToDQSUQBsezQafYRbmsaU5JSrZm8J4KB
XCmUWhmUzsKpn1ssHkXn
=zcX+
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to