diff options
Diffstat (limited to 'chrome_frame')
-rw-r--r-- | chrome_frame/chrome_active_document.cc | 8 | ||||
-rw-r--r-- | chrome_frame/chrome_frame_automation.cc | 7 |
2 files changed, 12 insertions, 3 deletions
diff --git a/chrome_frame/chrome_active_document.cc b/chrome_frame/chrome_active_document.cc index 2418413..35f72f3e 100644 --- a/chrome_frame/chrome_active_document.cc +++ b/chrome_frame/chrome_active_document.cc @@ -1010,8 +1010,12 @@ bool ChromeActiveDocument::LaunchUrl(const ChromeFrameUrl& cf_url, return true; automation_client_->SetUrlFetcher(url_fetcher_.get()); - return InitializeAutomation(GetHostProcessName(false), L"", IsIEInPrivate(), - false, cf_url.gurl(), GURL(referrer)); + if (launch_params_) { + return automation_client_->Initialize(this, launch_params_); + } else { + return InitializeAutomation(GetHostProcessName(false), L"", IsIEInPrivate(), + false, cf_url.gurl(), GURL(referrer)); + } } diff --git a/chrome_frame/chrome_frame_automation.cc b/chrome_frame/chrome_frame_automation.cc index 32fc24d..6f31bf7 100644 --- a/chrome_frame/chrome_frame_automation.cc +++ b/chrome_frame/chrome_frame_automation.cc @@ -613,7 +613,12 @@ bool ChromeFrameAutomationClient::Initialize( // InitializeComplete is called successfully. init_state_ = INITIALIZING; - HRESULT hr = security_manager_.CreateInstance(CLSID_InternetSecurityManager); + HRESULT hr = S_OK; + // If chrome crashed and is being restarted, the security_manager_ object + // might already be valid. + if (security_manager_.get() == NULL) + hr = security_manager_.CreateInstance(CLSID_InternetSecurityManager); + if (FAILED(hr)) { NOTREACHED() << __FUNCTION__ << " Failed to create InternetSecurityManager. Error: 0x%x" |