[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kmail-devel
Subject:    Re: [Patch] Improved threading (by references and subject)
From:       Ingo =?iso-8859-1?q?Kl=F6cker?= <kloecker () kde ! org>
Date:       2003-03-10 20:02:57
[Download RAW message or body]

On Monday 10 March 2003 09:24, Till Adam wrote:
> On Sunday 09 March 2003 23:38, Ingo Klöcker wrote:
> > On Sunday 09 March 2003 15:27, Till Adam wrote:
> > > On Sunday 09 March 2003 11:21, Ingo Klöcker wrote:
> > > > On Sunday 09 March 2003 09:38, Till Adam wrote:
> > > > > How about that imap patch, has someone seen problems with
> > > > > that?
> > > >
> > > > The additions to parseBody seem to be okay. But I'm not sure
> > > > about the change
> > > > -    retVal = parseOneWord(inWords);
> > > > +    retVal = parseOneWord(inWords, TRUE);
> > > > in parseLiteral. It was probably intentionally called with
> > > > FALSE (the default value). Therefore you should add a
> > > > stopAtBracket parameter with a default value of false to
> > > > parseLiteral.
> > >
> > > Like so?
> >
> > Not really.
> >
> > Why did you now make the following change in parseFetch?
> > -      QString word = parseLiteral (inWords);
> > +      QString word = parseLiteral (inWords, false, true);
> >
> > Actually I don't see why you made the following change in
> > parseLiteral (in the 1st version of this patch; which made me
> > propose to add the stopAtBracket parameter to parseLiteral).
> > -    retVal = parseOneWord(inWords);
> > +    retVal = parseOneWord(inWords, true);
> >
> > Do you still know why you made this change?
>
> Yes, I think I do. When parseFetch is entered with
>
> BODY[HEADER.FIELDS (References)] {n}
>
> It calls parseLiteral in line 1168 to get the first word of the
> remaining string. If that matches "BODY", parseBody is called, where
> the specifier HEADER.FIELDS is detected and the rest of the string
> properly parsed.
>
> This requires parseLiteral to stop at the "[" after BODY, which in
> turn requires it to call parseOneWord with stopAtBracket == true at
> line 1561.
>
> Since I figured (maybe wrongly) that stopping at a "[" is sensible
> default behaveour for parseLiteral, I added the true there. Since you
> wanted me to not change the default of false there, I now added a
> parameter to parseLiteral called stopAtBracket with a default of
> false which is passed along to parseOneWord at 1561.

Thanks for the explanation. AFAICS the changes in the imap kioslave are 
okay and ready to be committed.

Regards,
Ingo


[Attachment #3 (application/pgp-signature)]
_______________________________________________
KMail Developers mailing list
kmail@mail.kde.org
http://mail.kde.org/mailman/listinfo/kmail

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic