mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
ContextVK::Shutdown was clearing the context's fence_waiter_. This could cause crashes if a pending task such as image decoding is still holding a reference to the context after ContextVK::Shutdown is called. The image decode task will submit a command buffer through the context, and CommandQueueVK::Submit will get a null pointer deference when it tries to use the fence waiter. This PR changes ContextVK::Shutdown to terminate the fence waiter instead of clearing it. FenceWaiterVK::Terminate will now stop the waiter thread and wait for the thread to exit. This ensures that the fence waiter thread is stopped in ContextVK::Shutdown even if something else is holding a reference to the FenceWaiterVK. Tasks like image decoding will now get an error result instead of a crash when submitting a command buffer after context shutdown.
Flutter Engine
Setting up the Engine development environment
See here
gclient bootstrap
Flutter engine uses gclient to manage dependencies.
If you've already cloned the flutter repository: