[BUG] SqueakMap, MailComposition and SMTPClient

Mike Roberts mike at mjr104.co.uk
Wed Jul 30 14:47:15 UTC 2003


Hi,

I am unable to email people when clicking their SqueakMap entry in a (latest) default image.  I'm sorry if this is really obvious, I have done something stupid, or has been covered before.

The issue seems to be that some email addresses are (reasonably) of the form "Full Name <name at domain>" and MailComposition passes these straight through to SMTPClient.

The comment for SMTPClient>>mailFrom:to:text: says "no '<>' or '()' stuff".  

I'm thinking that MailComposition should filter this out and just send name at domain to SMTPClient but I'm not sure the original intent of this code.  

I'm also wondering that maybe people with Celeste registered as the mail app don't see this problem, although I haven't tried this to see.

Here is a small example.  You need to put in your email details.

|s m|
s _ 'From: name at domain'.
s _ s, String cr.
s _ s, 'To: Full Name <name at domain>'.
s _ s, String cr.
s _ s, 'Subject: Test'.
s _ s, String cr.
s _ s, String cr.
s _ s, 'This is a test'.
m _ MailComposition new.
m messageText:(Text fromString:s).
m submit

On an Exchange server I get a 501 5.5.4 invalid address.  On a qmail server I get a suitable mailer error response.

As a separate issue, why does MailComposition>>messageText: return true and not self?  This prevents you from chaining messages together.

Any help appreciated.

Cheers

Mike



More information about the Squeak-dev mailing list