[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdelibs/kross/ui
From: Nick Shaforostoff <shafff () ukr ! net>
Date: 2010-06-15 21:40:40
Message-ID: 20100615214040.B2D52AC8D4 () svn ! kde ! org
[Download RAW message or body]
SVN commit 1138383 by shaforo:
quick fix for Lokalize crash. It is presumably triggered when new script-actions are \
added. i guess the problem is that ActionCollection::addAction may remove an action \
silently w/o notifying the model
BUG: 240540
CCMAIL: danders@get2net.dk
CCMAIL: mail@dipe.org
M +5 -1 model.cpp
--- trunk/KDE/kdelibs/kross/ui/model.cpp #1138382:1138383
@@ -219,7 +219,11 @@
return 0;
}
ActionCollection* par = index.isValid() ? collection( index ) : d->collection;
- Q_ASSERT( par != 0 );
+ Q_ASSERT_X( par, "ActionCollectionModel::rowCount", "index is not an action nor \
a collection" ); + if (!par) {
+ qWarning()<<"index is not an action nor a collection"<<index;
+ return 0;
+ }
int rows = par->actions().count() + par->collections().count();
return rows;
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic