WebGPU: Fix use-after-free of device lost callback.
The device lost callback is stored in a unique_ptr since it may never be called. If it's never called we need to free the allocation on GPUDevice deletion. However, if it is called, we should release the managed pointer since the callback is self-deleting. Bug: 1160448 Change-Id: I780eae1dcb8fac34a0128351f47224c83d8c6727 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2612120Reviewed-by:Corentin Wallez <cwallez@chromium.org> Commit-Queue: Austin Eng <enga@chromium.org> Cr-Commit-Position: refs/heads/master@{#841173}
Showing
Please register or sign in to comment