1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 09:32:12 +01:00

[Crash] Fixed occasional crash when extracting form data from page.

Apparently, QWebFrame::childFrames can return NULL frame.
This commit is contained in:
nowrep 2013-04-21 20:44:08 +02:00
parent 9861af4d64
commit 482cb18ce4

View File

@ -239,8 +239,10 @@ QWebElementCollection PageFormCompleter::getAllElementsFromPage(QWebPage* page,
frames.append(page->mainFrame());
while (!frames.isEmpty()) {
QWebFrame* frame = frames.takeFirst();
list.append(frame->findAllElements(selector));
frames += frame->childFrames();
if (frame) {
list.append(frame->findAllElements(selector));
frames += frame->childFrames();
}
}
return list;