actually need to update queueCount otherwise we just go until we run out of sources and an assert due to dequeuing an empty stack. whoops.

svn path=/branches/KDE/4.2/kdelibs/; revision=914769
This commit is contained in:
Aaron J. Seigo 2009-01-21 18:24:47 +00:00
parent c989e14438
commit cba376cd4c

View File

@ -636,9 +636,10 @@ DataContainer *DataEnginePrivate::requestSource(const QString &sourceName, bool
void DataEnginePrivate::trimQueue()
{
uint queueCount = sourceQueue.count();
while (queueCount >= limit) {
while (queueCount >= limit && !sourceQueue.isEmpty()) {
DataContainer *punted = sourceQueue.dequeue();
q->removeSource(punted->objectName());
queueCount = sourceQueue.count();
}
}