james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Peter M. Goldstein" <peter_m_goldst...@yahoo.com>
Subject RFC 2822 Header Name Unification
Date Wed, 11 Sep 2002 08:46:17 GMT
All,

 

Attached is a patch that is intended to reduce the use of "magic
strings" in the James source code (it is the first of several such
patches).

 

This patch adds all header names explicitly specified in RFC 2822 as
static constants in the MailHeaders class.  The header names explicitly
specified throughout the code are replaced with references to these
static constants.  This should simplify mail header manipulation in the
code and protect against the odd typo.

 

In the process of making this change a minor bug was discovered.
MailImpl.java used the header name "Message-Id" as opposed to
"Message-ID", which is the value specified in RFC 2822 for the message
id header.  This patch resolves this problem.

 

If there are no objections I'll submit this patch.

 

--Peter


Mime
View raw message