Hi,
Kopete Gadu-Gadu protocol causes SEGFAULTs after logging in. The problem is that GaduContactList() assumes static CSV column count. Problem
occurs if someone has 12/13 columns in his contact list but no 14'th.

This patch simply checks that strList.count() is big enough to access next stringIterator. Works perfectly with my "broken" contact list.

Closes bug #166465

Regards,
Kamil KamiƄski
Index: protocols/gadu/gaducontactlist.cpp
===================================================================
--- protocols/gadu/gaducontactlist.cpp  (wersja 837988)
+++ protocols/gadu/gaducontactlist.cpp  (kopia robocza)
@@ -104,10 +104,10 @@
                        ++stringIterator;
                        ++stringIterator;
 
-                       if ( stringIterator != strList.end() ) {
+                       if ( strList.count() >= 13 )
                                cl.offlineTo = (*++stringIterator) == 
QString('0') ? false : true;
+                       if ( strList.count() >= 14 )
                                cl.landline  = (*++stringIterator);
-                       }
                }
                else {
                         cl.email       = empty;

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

_______________________________________________
kopete-devel mailing list
[email protected]
https://mail.kde.org/mailman/listinfo/kopete-devel

Reply via email to