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

List:       kmail-devel
Subject:    Re: Bug#27700: search folders hangs kmail
From:       Michael =?iso-8859-1?q?H=E4ckel?= <Michael () Haeckel ! Net>
Date:       2001-07-08 14:02:27
[Download RAW message or body]

On Monday, 25. June 2001 23:07, Achim Bohnet wrote:
>
> I've placed the mbox at http://www.xray.mpe.mpg.de/~ach/tru64.mbox.bz2
> (still 2.8MB unfortunately)
>
> > Does KMail run at 100% CPU or does it simply nothing?
>
> Ups, 100% CPU.    And Marc is right:  With the tru64 mbox file
> 'search folders' dialog 'hangs' with '... (400 messages)' in the
> status bar and after ~ 6 minutes the search runs to it's end
> (well, call me impatient.  Never waited that long ;)
> I've looked at the mbox file at message 400 +- 1 without seeing
> something strange :(

Fixed, the problematic mail probably contained _many_ ">" characters.

That is probably also the reason, why huge HTML mails were slow, they also 
contain many of these characters.

Regards,
Michael Häckel

Index: kmmessage.cpp
===================================================================
RCS file: /home/kde/kdenetwork/kmail/kmmessage.cpp,v
retrieving revision 1.212
diff -u -3 -p -r1.212 kmmessage.cpp
--- kmmessage.cpp       2001/07/08 09:49:10     1.212
+++ kmmessage.cpp       2001/07/08 13:58:38
@@ -194,7 +194,8 @@ void KMMessage::fromString(const QCStrin
 //  ISO-2022-JP code consists of ESC(0x1b) character and 7Bit character which
 //  used from '!' character to  '~' character.  toyo
     if ((ch>=' ' || ch=='\t' || ch=='\n' || ch<='\0' || ch == 0x1b)
-       && !(ch=='>' && aStr.mid(strPos-aStr.data()-1,6)=="\n>From"))
+       && !(ch=='>' && strPos > aStr.data()
+            && qstrncmp(strPos-1, "\n>From", 6) == 0))
       *resultPos++ = ch;
   }
   *resultPos = '\0'; // terminate zero for casting
_______________________________________________
Kmail Developers mailing list
Kmail@master.kde.org
http://master.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