================================================================
Dear Bug Team!
I get lots of mail with RFC2047-encoded From: fields (I use
Gnus). Mostly ISO-8859-2. Now, when mail-extr.el
(mail-extract-address-components) gets to those headers, they are
already in decoded form, which causes mail-extr to fail. I get chopped
names, annoying BBDB behavior, and all sorts of breakage. As an example,
if sender's name contains an 'ł', mail-extract-address-components will
return his name only up to (not containing) this character.
People who get ISO-8859-1 E-mail probably don't see this, because
mail-extr.el is "extended" to handle ISO-8859-1 in a particularly ugly
way.
I've reported this on the Gnus mailing list and got this reply:
From: Dave Love <d.love(a)dl.ac.uk>
Subject: Re: something decodes my headers...
To: Jan Rychter <jan(a)rychter.com>
Cc: ding(a)gnus.org
Date: Thu, 12 Jun 2003 23:38:19 +0100
Jan Rychter <jan(a)rychter.com> writes:
People who get
ISO-8859-1 E-mail don't see this, because mail-extr.el is "extended" to
handle ISO-8859-1 in a particularly ugly way.
That must be XEmacs-specific. mail-extr in Emacs (at least Emacs 21)
works with multilingual text.
I've tried to trace what it is that decodes the headers to 8bit
before
mail-extr sees them -- but I have no idea.
I think that's the wrong thing to look at. mail-extr should just cope
with multilingual names. [If it's really `8-bit' I assume it's a
non-Mule XEmacs, so you can't deal with multilingual text anyhow.]
And indeed, the Emacs version of mail-extr.el seems to use [:alnum:] and
[:alpha:]:
(defconst mail-extr-all-letters-but-separators
(purecopy "][[:alnum:]{|}'~`"))
instead of (in the XEmacs version):
(defconst mail-extr-all-letters-but-separators
(purecopy "][A-Za-z{|}'~0-9`\200-\376")) ;; XEmacs
Now, opinions are divided on whether mail-extract-address-components
should really get multilingual text or not. In any case, the current
solution is rather broken.
How can this be fixed?
--J.
================================================================
System Info to help track down your bug:
---------------------------------------
uname -a: Linux
tnuctip.rychter.com 2.4.21-rc1 #5 Sun Apr 27 20:45:38 CEST 2003 i686 i686
i386 GNU/Linux
./configure '--with-mule' '--error-checking=none'
'--with-menubars=lucid' '--with-scrollbars=lucid'
'--with-dialogs=athena' '--with-widgets=athena' '--with-athena=3d'
'--with-sound=no' '--pdump'
XEmacs 21.4.12 "Portable Code" configured for `i686-pc-linux'.
Compilation / Installation:
Source code location: /usr/src/xemacs/xemacs-21.4.12
Installation prefix: /usr/local
Operating system description file: `s/linux.h'
Machine description file: `m/intel386.h'
Compiler: gcc -g -O3 -Wall -Wno-switch -Winline
-Wmissing-prototypes -Wsign-compare -Wshadow
Relocating allocator for buffers: no
GNU version of malloc: yes
- Using Doug Lea's new malloc from the GNU C Library.
Window System:
Compiling in support for the X window system:
- X Windows headers location: /usr/X11R6/include
- X Windows libraries location: /usr/X11R6/lib
- Handling WM_COMMAND properly.
Compiling in support for the Athena widget set:
- Athena headers location: X11/Xaw3d
- Athena library to link: Xaw3d
Using Lucid menubars.
Using Lucid scrollbars.
Using Athena dialog boxes.
Using Athena native widgets.
TTY:
Compiling in support for ncurses.
Compiling in support for GPM (General Purpose Mouse).
Images:
Compiling in support for GIF images (builtin).
Compiling in support for XPM images.
Compiling in support for PNG images.
Compiling in support for JPEG images.
Compiling in support for TIFF images.
Sound:
Databases:
Compiling in support for Berkeley database.
Compiling in support for LDAP.
Compiling in support for PostgreSQL.
- Using PostgreSQL header file: libpq-fe.h
- Using PostgreSQL V7 bindings.
Internationalization:
Compiling in support for Mule (multi-lingual Emacs).
Compiling in support for XIM (X11R5+ I18N input method).
- Using Motif to provide XIM support.
Compiling in support for Canna on Mule.
Compiling in support for the WNN input method on Mule.
Mail:
Compiling in support for "dot-locking" mail spool file locking method.
Other Features:
Inhibiting IPv6 canonicalization at startup.
Compiling in support for dynamic shared object modules.
Using the new portable dumper.