[Kde-pim] Review Request 113933: Don't say we can fetchMore if we really can't.

Christian Mollekopf chrigi_1 at fastmail.fm
Tue Nov 19 09:55:45 GMT 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/113933/
-----------------------------------------------------------

Review request for KDEPIM-Libraries.


Repository: kdepimlibs


Description
-------

Don't say we can fetchMore if we really can't.

Since we purge all items, the usual checks apply. This extra check was meant to get items updated
that were still cached, but potentially outdated since we didn't receive any updates due to the collection not being monitored.

Due to the "always true if !monitored", it would be possible to endlessly refetch items of a non monitored collection,
which is not what we want.


While I couldn't find the exact codepath, this may be responsible for an endless fetch loop Georg is experiencing. I'm not sure though as EntityTreeModelPrivate::canFetchMore is not exposed from EntityTreeModel::canFetchMore, and calling EntityTreeModel::fetchMore twice shouldn't emit signals in any case (the items are fetched again without the patch, but no signals are emitted as the items are already in the model).

That said, it's in any case a bug in the code that should be fixed.


Diffs
-----

  akonadi/entitytreemodel_p.cpp e15646058bc85cd1cac0e3815dce87324b9cb3de 
  akonadi/tests/lazypopulationtest.cpp 6a884b33187b9bcf1b42902a2214e6c28476aca9 

Diff: http://git.reviewboard.kde.org/r/113933/diff/


Testing
-------


Thanks,

Christian Mollekopf

_______________________________________________
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