diff --git a/libcef/browser/browser_host_impl_mac.mm b/libcef/browser/browser_host_impl_mac.mm index ea93838f1..1be22e515 100644 --- a/libcef/browser/browser_host_impl_mac.mm +++ b/libcef/browser/browser_host_impl_mac.mm @@ -389,9 +389,10 @@ bool CefBrowserHostImpl::PlatformCreateWindow() { void CefBrowserHostImpl::PlatformCloseWindow() { if (window_info_.view != nil) { - [[window_info_.view window] performSelector:@selector(performClose:) - withObject:nil - afterDelay:0]; + [[window_info_.view window] + performSelectorOnMainThread:@selector(performClose:) + withObject:nil + waitUntilDone:NO]; } }