Pass the correct buffer when creating TcpSocket
This commit is contained in:
parent
c21cc21c62
commit
768fe699cf
1 changed files with 1 additions and 1 deletions
|
@ -389,7 +389,7 @@ pub mod client {
|
||||||
fn new<D: Driver>(stack: &'d Stack<D>, state: &'d TcpClientState<N, TX_SZ, RX_SZ>) -> Result<Self, Error> {
|
fn new<D: Driver>(stack: &'d Stack<D>, state: &'d TcpClientState<N, TX_SZ, RX_SZ>) -> Result<Self, Error> {
|
||||||
let mut bufs = state.pool.alloc().ok_or(Error::ConnectionReset)?;
|
let mut bufs = state.pool.alloc().ok_or(Error::ConnectionReset)?;
|
||||||
Ok(Self {
|
Ok(Self {
|
||||||
socket: unsafe { TcpSocket::new(stack, &mut bufs.as_mut().0, &mut bufs.as_mut().1) },
|
socket: unsafe { TcpSocket::new(stack, &mut bufs.as_mut().1, &mut bufs.as_mut().0) },
|
||||||
state,
|
state,
|
||||||
bufs,
|
bufs,
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue