On Thu, 2005-11-10 at 12:14 -0800, K C wrote:

[lots of snipping]
> So my guess about how IMAPd working is it took whatever encoding it
> saw when startup and never change it.  Is it true?  And if so, is it
> true to other daemons?
> 
DBMail does not consider the encoding of the database, but rather
assumes that whatever bytes are sent to the database will be stored that
way and subsequently retrieved in the same way. What PostgreSQL is
trying to do is enforce the correctness of the encoding. We don't really
care at this time. Hence the conflict.

Remember that email comes in off the wire from a hostile Internet. I do
not believe it is DBMail's place to consider keeping or not keeping
email on the basis of how well it conforms to the encoding it claims to
have. That's somebody else's problem, namely the MUA (mail user agent). 

All DBMail needs to do is be reliable at receiving, storing and
retrieving that message.

> I think the daemons should be able to detect what kind of encoding the
> source is and set it accordingly.

> Do you think this a bug?

In 2.0.7 I inserted a check that causes DBMail to bomb out on startup
with a warning that the database must be US-ASCII. In 2.1.x I'd like to
do something more clever, like change the encoding at connection time.

Aaron

Reply via email to