Fix crash in CefTaskRunnerImpl::GetTaskRunner when CEF is not initialized (issue #1925)

This commit is contained in:
Marshall Greenblatt 2016-06-15 14:11:30 -04:00
parent 6ee1922b2c
commit 1fbc5c4393
1 changed files with 2 additions and 1 deletions

View File

@ -85,7 +85,8 @@ scoped_refptr<base::SequencedTaskRunner>
break; break;
}; };
if (id >= 0 && CefContentClient::Get()->browser() && if (id >= 0 && CefContentClient::Get() &&
CefContentClient::Get()->browser() &&
BrowserThread::IsMessageLoopValid(static_cast<BrowserThread::ID>(id))) { BrowserThread::IsMessageLoopValid(static_cast<BrowserThread::ID>(id))) {
// Don't use BrowserThread::GetMessageLoopProxyForThread because it returns // Don't use BrowserThread::GetMessageLoopProxyForThread because it returns
// a new MessageLoopProxy object for each call and makes pointer equality // a new MessageLoopProxy object for each call and makes pointer equality