KSelectionProxyModel problem

Ilya Matveychikov matvejchikov at gmail.com
Sun Sep 6 21:26:47 UTC 2015


$ git log -1

ASSERT: "m_mappedFirstChildren.isEmpty()" in file
kitemmodels/kselectionproxymodel.cpp, line 1989
Segmentation fault (core dumped)

Test case:

1) run TreeModel
2) select "B"
3) type "c" in edit, then backspace
4) type "f" in edit, then backspace
5) type "x" in edit -> CRASH

2015-09-07 0:12 GMT+03:00 Albert Astals Cid <aacid at kde.org>:
> El Divendres, 4 de setembre de 2015, a les 13:43:36, Ilya Matveychikov va
> escriure:
>> Here is  the KSelectionProxyModel model
>>
>> problem. It crashes with segmentation fault while selection/deselection
>> occurs...
>
> Does not crash here. What do you do to make it crash?
>
> Do you have a gdb/valgrind trace?
>
> Cheers,
>   Albert
>
>>
>> Test sample and the case:
>> https://github.com/milabs/QtSampleModel/tree/treemodel
>>
>> Also, looks like that model doesn't operate with QTableView
>>
>> correctly. The patch shows the problem
>>
>> place:
>>
>> @@ -2446,7 +2446,7 @@ int KSelectionProxyModela(const
>> QModelIndex &index) const
>>              // it's actually 0 ,but must return what the source model
>> says, even if we
>>              // have no rows or columns.
>>  #if QT_VERSION >= 0x040700
>> -            || d->m_rootIndexList.isEmpty()
>> +//            || d->m_rootIndexList.isEmpty()
>>  #endif
>>         ) {
>>          return 0;
>


More information about the Kde-frameworks-devel mailing list