diff --git a/protocol/src/lib.rs b/protocol/src/lib.rs index e0d43da..c1c301c 100644 --- a/protocol/src/lib.rs +++ b/protocol/src/lib.rs @@ -980,8 +980,8 @@ impl fmt::Display for ProtocolError { #[cfg(feature = "async")] pub struct AsyncProtocol where - R: AsyncRead + Unpin, - W: AsyncWrite + Unpin, + R: AsyncRead + Unpin + Send, + W: AsyncWrite + Unpin + Send, { reader: AsyncProtocolReader, writer: AsyncProtocolWriter, @@ -990,8 +990,8 @@ where #[cfg(feature = "async")] impl AsyncProtocol where - R: AsyncRead + Unpin, - W: AsyncWrite + Unpin, + R: AsyncRead + Unpin + Send, + W: AsyncWrite + Unpin + Send, { /// New protocol session which completes the initial handshake and returns a handler. /// @@ -1115,7 +1115,7 @@ enum DecryptState { #[cfg(feature = "async")] pub struct AsyncProtocolReader where - R: AsyncRead + Unpin, + R: AsyncRead + Unpin + Send, { buffer: R, packet_reader: PacketReader, @@ -1125,7 +1125,7 @@ where #[cfg(feature = "async")] impl AsyncProtocolReader where - R: AsyncRead + Unpin, + R: AsyncRead + Unpin + Send, { /// Decrypt contents of received packet from buffer. /// @@ -1162,7 +1162,7 @@ where #[cfg(feature = "async")] pub struct AsyncProtocolWriter where - W: AsyncWrite + Unpin, + W: AsyncWrite + Unpin + Send, { buffer: W, packet_writer: PacketWriter, @@ -1171,7 +1171,7 @@ where #[cfg(feature = "async")] impl AsyncProtocolWriter where - W: AsyncWrite + Unpin, + W: AsyncWrite + Unpin + Send, { /// Encrypt contents and write packet buffer. ///