flutter-plugins
flutter-plugins copied to clipboard
[desktop_webview_window v0.2.3] Webview crashes if window is manipulated before fully initializing
When the webview window is created, if you press minimize too early the entire application crashes.
Reproduce Steps
Steps to reproduce the behavior:
- Open Flutter app
- Call WebviewWindow.create
- As soon as window opens, press minimize
- App crashes
Expected behavior
The window should minimize without crashing
Version (please complete the following information):
- Flutter 3.22.3, Dart 3.4.4
- Windows 11 Pro | 23H2 | 22631.3880
- desktop_webview_window v0.2.3
EXCEPTION_ACCESS_VIOLATION_READ / 0x0
- webview_window::WebView::UpdateBounds (web_view.cc:202)
note that adding null check resolves issue and everything behaves as expected, haven't delved deep enough to see if has any repercussions
Here's the parameters the webview is initialized with
If the window is closed before complete initialization, Webview will also crash
如果在完成初始化之前关闭窗口,Webview 也会崩溃