add comment about the usage of Arc
This commit is contained in:
parent
6c983a7335
commit
a8e3746e91
|
@ -35,6 +35,9 @@ impl Drop for Socket {
|
|||
}
|
||||
}
|
||||
|
||||
// Arc is used to count the number of used sockets.
|
||||
// Only if all sockets are released, the drop
|
||||
// method will close the socket.
|
||||
#[derive(Clone)]
|
||||
pub struct TcpStream(Arc<Socket>);
|
||||
|
||||
|
|
Loading…
Reference in New Issue