Checking for nullnes is unnecessary

If the memory allocation fails we are screwed anyway
This commit is contained in:
Filippo Cucchetto 2016-01-28 21:33:06 +01:00
parent ed8cb13083
commit 548b7f4e50
1 changed files with 0 additions and 1 deletions

View File

@ -123,7 +123,6 @@ void dos_qqmlapplicationengine_rootObjects(void *vptr, void *** array, int *arra
auto engine = static_cast<QQmlApplicationEngine *>(vptr);
QList<QObject *> list = engine->rootObjects();
void** objects = new void*[list.size()];
if (objects == nullptr) return;
for (int i = 0; i < list.size(); ++i)
objects[i] = static_cast<QObject*>(list.at(i));
*array = static_cast<void **>(objects);