mirror of
				https://bitbucket.org/chromiumembedded/cef
				synced 2025-06-05 21:39:12 +02:00 
			
		
		
		
	Fix race condition during V8 proxy initialization (issue #912).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1252 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
		@@ -93,16 +93,19 @@ int CefBrowserMainParts::PreCreateThreads() {
 | 
			
		||||
void CefBrowserMainParts::PreMainMessageLoopRun() {
 | 
			
		||||
  browser_context_.reset(new CefBrowserContext());
 | 
			
		||||
 | 
			
		||||
  // Initialize the request context getter.
 | 
			
		||||
  _Context->set_request_context(browser_context_->GetRequestContext());
 | 
			
		||||
 | 
			
		||||
  // Initialize proxy configuration service.
 | 
			
		||||
  // Initialize the proxy configuration service. This needs to occur before
 | 
			
		||||
  // CefURLRequestContextGetter::GetURLRequestContext() is called for the
 | 
			
		||||
  // first time.
 | 
			
		||||
  ChromeProxyConfigService* chrome_proxy_config_service =
 | 
			
		||||
      ProxyServiceFactory::CreateProxyConfigService();
 | 
			
		||||
  proxy_config_service_.reset(chrome_proxy_config_service);
 | 
			
		||||
  pref_proxy_config_tracker_->SetChromeProxyConfigService(
 | 
			
		||||
      chrome_proxy_config_service);
 | 
			
		||||
 | 
			
		||||
  // Initialize the request context getter. This indirectly triggers a call
 | 
			
		||||
  // to CefURLRequestContextGetter::GetURLRequestContext() on the IO thread.
 | 
			
		||||
  _Context->set_request_context(browser_context_->GetRequestContext());
 | 
			
		||||
 | 
			
		||||
  const CommandLine& command_line = *CommandLine::ForCurrentProcess();
 | 
			
		||||
  if (command_line.HasSwitch(switches::kRemoteDebuggingPort)) {
 | 
			
		||||
    std::string port_str =
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user