users@glassfish.java.net

Re: JavaMail: How to step into with NetBeans debugger?

From: <glassfish_at_javadesktop.org>
Date: Thu, 20 Dec 2007 05:13:57 PST

> > I am reading messages not constructing them and when
> > I step into getHeader I get that code with
> > "addReverse". I'd really appreciate a way to always
> > get them in the order presented.

I apologize for that statement, sometimes the only exercise I get is jumping to conclusions.

> addReverse is a local variable of the addHeader method.
> It's hard to imagine how you're seeing it in the getHeader
> method. Are you sure you're looking in
> javax.mail.internet.InternetHeaders?

The call stack at that point looks like:
InternetHeaders.addHeader:484
Hidden Source Calls
  MetaMessageImpl.getHeaders
  MStorMessage.getHeader
MessageProcessor.processMessage 127
Main.main:185

>
> When you find a message that has this problem, does
> the problem reproduce with that message every time?

Yes. I should be able to come up with a 2 message dataset that does one one way and the other the opposite.

> How do you know it's doing the wrong thing? Are you comparing the
> raw MIME message data with the data you're getting from JavaMail?

Yes, looking at the mbox with vi they are reversed. Plus I'm looking for the one received by my mail server, which is the first one in the MIME message


> It's probably time to look at mstor and how it's handling headers.

I believe you're right. I'll get the sources.

Joe
[Message sent by forum member 'areeda' (areeda)]

http://forums.java.net/jive/thread.jspa?messageID=250943