about summary refs log tree commit diff
path: root/library/std/src/sys/sync/rwlock/queue.rs
diff options
context:
space:
mode:
Diffstat (limited to 'library/std/src/sys/sync/rwlock/queue.rs')
-rw-r--r--library/std/src/sys/sync/rwlock/queue.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/std/src/sys/sync/rwlock/queue.rs b/library/std/src/sys/sync/rwlock/queue.rs
index d1918855797..337cc6c2ca0 100644
--- a/library/std/src/sys/sync/rwlock/queue.rs
+++ b/library/std/src/sys/sync/rwlock/queue.rs
@@ -202,7 +202,7 @@ impl Node {
     fn prepare(&mut self) {
         // Fall back to creating an unnamed `Thread` handle to allow locking in
         // TLS destructors.
-        self.thread.get_or_init(|| thread::try_current().unwrap_or_else(|| Thread::new(None)));
+        self.thread.get_or_init(|| thread::try_current().unwrap_or_else(Thread::new_unnamed));
         self.completed = AtomicBool::new(false);
     }