From eb37bbcebc3f6d0981eef892817f3a4570e35907 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Thu, 19 May 2022 06:41:35 -0700 Subject: Document that `BorrowedFd` may be used to do a `dup`. --- library/std/src/sys/windows/handle.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'library/std/src/sys') diff --git a/library/std/src/sys/windows/handle.rs b/library/std/src/sys/windows/handle.rs index ef9a8bd6900..1e7b6e1eab0 100644 --- a/library/std/src/sys/windows/handle.rs +++ b/library/std/src/sys/windows/handle.rs @@ -218,7 +218,7 @@ impl Handle { inherit: bool, options: c::DWORD, ) -> io::Result { - Ok(Self(self.0.duplicate(access, inherit, options)?)) + Ok(Self(self.0.as_handle().duplicate(access, inherit, options)?)) } /// Performs a synchronous read. -- cgit 1.4.1-3-g733a5