Permalink
Browse files

Revert "Fix crash on exit (Issues #136, #148 and #149)"

This reverts commit 5acaa6b.

Conflicts:

	src/phantom.cpp
	src/phantom.h

removed m_page deletion.

http://code.google.com/p/phantomjs/issues/detail?id=719
  • Loading branch information...
1 parent 9f80563 commit ecda22423386e7353246577ed58b16d2fe792c8b Shawn Krisman committed with Aug 19, 2012
Showing with 0 additions and 10 deletions.
  1. +0 −8 src/phantom.cpp
  2. +0 −1 src/phantom.h
  3. +0 −1 src/webpage.cpp
View
@@ -93,7 +93,6 @@ void Phantom::init()
CookieJar::instance(m_config.cookiesFile());
m_page = new WebPage(this, QUrl::fromLocalFile(m_config.scriptFile()));
- m_pages.append(m_page);
QString proxyType = m_config.proxyType();
if (proxyType != "none") {
@@ -265,10 +264,6 @@ void Phantom::setCookiesEnabled(const bool value)
QObject *Phantom::createWebPage()
{
WebPage *page = new WebPage(this);
-
- // Store pointer to the page for later cleanup
- m_pages.append(page);
- // Apply default settings to the page
page->applySettings(m_defaultPageSettings);
// Show web-inspector if in debug mode
@@ -407,9 +402,6 @@ void Phantom::doExit(int code)
emit aboutToExit(code);
m_terminated = true;
m_returnValue = code;
- qDeleteAll(m_pages);
- m_pages.clear();
- m_page = 0;
QApplication::instance()->exit(code);
}
View
@@ -182,7 +182,6 @@ private slots:
QVariantMap m_defaultPageSettings;
FileSystem *m_filesystem;
System *m_system;
- QList<QPointer<WebPage> > m_pages;
QList<QPointer<WebServer> > m_servers;
Config m_config;
View
@@ -189,7 +189,6 @@ public slots:
newPage = new WebPage(m_webPage);
} else {
newPage = new WebPage(Phantom::instance());
- Phantom::instance()->m_pages.append(newPage);
}
// Apply default settings

0 comments on commit ecda224

Please sign in to comment.