1
0
Fork 0
mirror of https://github.com/thoughtbot/capybara-webkit synced 2023-03-27 23:22:28 -04:00

Use deleteLater to avoid possible null pointer crashes

This commit is contained in:
Joe Ferris 2014-06-27 10:00:48 -04:00 committed by Matthew Horan
parent e0172bfcd9
commit cddba4c9e1

View file

@ -122,7 +122,7 @@ void WebPageManager::reset() {
m_currentPage->resetLocalStorage();
while (!m_pages.isEmpty()) {
WebPage *page = m_pages.takeFirst();
delete page;
page->deleteLater();
}
createPage()->setFocus();
}