Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
5.9.3
-
None
Description
bool QStandardItemPrivate::insertRows(int row, const QList<QStandardItem*> &items) { Q_Q(QStandardItem); if ((row < 0) || (row > rowCount())) return false; int count = items.count(); if (model) model->d_func()->rowsAboutToBeInserted(q, row, row + count - 1);
If 'count' is 0 and 'row' is 0, than 'row + count - 1' will -1.
In this situation QAbstractItemModel::beginInsertRows failed on
Q_ASSERT(last >= first);