[Kde-pim] branches/work/kdepim-3.5.5+/kmail

Adriaan de Groot groot at kde.org
Wed Feb 14 05:12:50 GMT 2007


SVN commit 633413 by adridg:

Stop KMail from crashing all the time in PIM+; check if the data range in the index for this message would make sense at all. If not, no string part. Needs r. 633411 API changes.

CCMAIL: kde-pim at kde.org


 M  +5 -0      branches/work/kdepim-3.5.5+/kmail/kmmsgbase.cpp  


--- branches/work/kdepim-3.5.5+/kmail/kmmsgbase.cpp #633412:633413
@@ -1134,6 +1134,11 @@
     if (g_chunk)
       free(g_chunk);
     using_mmap = true;
+    if ( mIndexOffset > storage()->indexStreamLength() ) {
+      // This message has not been indexed yet, data would lie
+      // outside the index data structures so do not touch it.
+      return QString();
+    }
     g_chunk = storage()->indexStreamBasePtr() + mIndexOffset;
     g_chunk_length = mIndexLength;
   } else {
_______________________________________________
kde-pim mailing list
kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
kde-pim home page at http://pim.kde.org/



More information about the kde-pim mailing list