dawn/wire: Fix dangling pointer on client::Device::mQueue

Bug: dawn:2345
Change-Id: I3ebb065a81bc59b46e82899ee920b1905ceb8d3f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/182800
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
diff --git a/src/dawn/wire/client/Device.cpp b/src/dawn/wire/client/Device.cpp
index d7d2620..a54d3e5 100644
--- a/src/dawn/wire/client/Device.cpp
+++ b/src/dawn/wire/client/Device.cpp
@@ -200,7 +200,7 @@
 
 Device::~Device() {
     if (mQueue != nullptr) {
-        GetProcs().queueRelease(ToAPI(mQueue));
+        GetProcs().queueRelease(ToAPI(mQueue.ExtractAsDangling()));
     }
 }
 
diff --git a/src/dawn/wire/client/Device.h b/src/dawn/wire/client/Device.h
index 9b081f1..6d16647 100644
--- a/src/dawn/wire/client/Device.h
+++ b/src/dawn/wire/client/Device.h
@@ -105,8 +105,7 @@
     raw_ptr<void, DanglingUntriaged> mDeviceLostUserdata = nullptr;
     raw_ptr<void> mLoggingUserdata = nullptr;
 
-    // TODO(https://crbug.com/dawn/2345): Investigate `DanglingUntriaged` in dawn/wire:
-    raw_ptr<Queue, DanglingUntriaged> mQueue = nullptr;
+    raw_ptr<Queue> mQueue = nullptr;
 
     std::shared_ptr<bool> mIsAlive;
 };