Fix heap-use-after-free in CefBrowserMessageFilter::OnFrameFocused (issue #1567).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@2049 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
parent
5f3df0b702
commit
a4c4246897
|
@ -35,6 +35,8 @@ void CefBrowserMessageFilter::OnFilterAdded(IPC::Sender* sender) {
|
|||
}
|
||||
|
||||
void CefBrowserMessageFilter::OnFilterRemoved() {
|
||||
host_ = NULL;
|
||||
sender_ = NULL;
|
||||
}
|
||||
|
||||
bool CefBrowserMessageFilter::OnMessageReceived(const IPC::Message& message) {
|
||||
|
@ -124,6 +126,9 @@ void CefBrowserMessageFilter::OnFrameFocused(int32 render_frame_routing_id) {
|
|||
return;
|
||||
}
|
||||
|
||||
if (!host_)
|
||||
return;
|
||||
|
||||
CefRefPtr<CefBrowserHostImpl> browser =
|
||||
CefBrowserHostImpl::GetBrowserForFrame(host_->GetID(),
|
||||
render_frame_routing_id);
|
||||
|
|
Loading…
Reference in New Issue