mirror of
https://github.com/denoland/deno.git
synced 2024-12-01 16:51:13 -05:00
revert unnecessary change
This commit is contained in:
parent
60b3f3742d
commit
17bb2c46eb
1 changed files with 1 additions and 4 deletions
|
@ -333,10 +333,7 @@ pub fn take_network_stream_resource(
|
|||
if let Ok(resource_rc) = resource_table.take::<TcpStreamResource>(stream_rid)
|
||||
{
|
||||
// This TCP connection might be used somewhere else.
|
||||
let resource: crate::io::FullDuplexResource<
|
||||
tokio::net::tcp::OwnedReadHalf,
|
||||
tokio::net::tcp::OwnedWriteHalf,
|
||||
> = Rc::try_unwrap(resource_rc)
|
||||
let resource = Rc::try_unwrap(resource_rc)
|
||||
.map_err(|_| bad_resource("TCP stream is currently in use"))?;
|
||||
let (read_half, write_half) = resource.into_inner();
|
||||
let tcp_stream = read_half.reunite(write_half)?;
|
||||
|
|
Loading…
Reference in a new issue