Skip to content
This repository has been archived by the owner on Oct 30, 2023. It is now read-only.

Commit

Permalink
fix: crash when WindowButtonsProxy references cleared NSWindow (elect…
Browse files Browse the repository at this point in the history
…ron#33069)

* resets WindowButtonsProxy on window delete on macOS

* fixes reset
  • Loading branch information
gerhardberger authored and khalwa committed Feb 22, 2023
1 parent 84d33bd commit f762250
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions shell/browser/native_window_mac.mm
Expand Up @@ -328,6 +328,8 @@ void ViewDidMoveToSuperview(NSView* self, SEL _cmd) {
[](NativeWindowMac* window) {
if (window->window_)
window->window_ = nil;
if (window->buttons_proxy_)
window->buttons_proxy_.reset();
},
this));

Expand Down

0 comments on commit f762250

Please sign in to comment.