mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-07-05 04:36:02 +00:00
After the server is destroyed, the server's can't do anything like forward callbacks to the client. Track this with a weak_ptr and return early if it has expired. It also updates device destruction in dawn_native so the lost callback is always called, even on graceful destruction. This is consistent with the rest of WebGPU where all callbacks are guaranteed to be called in finite time. Bug: chromium:1147416, chromium:1161943 Change-Id: Ib80dea36517401a2b8eafb01ded255ebbe757aef Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/35840 Commit-Queue: Austin Eng <enga@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>