Updated embedded-io
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
* SOFTWARE.
|
||||
*/
|
||||
|
||||
use embedded_io::asynch::{Read, Write};
|
||||
use embedded_io_async::{Read, Write};
|
||||
use heapless::Vec;
|
||||
use rand_core::RngCore;
|
||||
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
use embedded_io::asynch::{Read, Write};
|
||||
use embedded_io_async::{Read, Write};
|
||||
use heapless::Vec;
|
||||
use rand_core::RngCore;
|
||||
|
||||
use crate::{
|
||||
encoding::variable_byte_integer::{VariableByteInteger, VariableByteIntegerDecoder},
|
||||
network::NetworkConnection,
|
||||
packet::v5::{
|
||||
connack_packet::ConnackPacket,
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
*/
|
||||
|
||||
use crate::packet::v5::reason_codes::ReasonCode;
|
||||
use embedded_io::asynch::{Read, Write};
|
||||
use embedded_io_async::{Read, Write};
|
||||
|
||||
pub struct NetworkConnection<T>
|
||||
where
|
||||
|
||||
@@ -90,7 +90,7 @@ impl<'a> BuffWriter<'a> {
|
||||
if self.position + len > self.len {
|
||||
return Err(BufferError::InsufficientBufferSize);
|
||||
}
|
||||
self.buffer[self.position..self.position+len].copy_from_slice(&array[0..len]);
|
||||
self.buffer[self.position..self.position + len].copy_from_slice(&array[0..len]);
|
||||
self.increment_position(len);
|
||||
Ok(())
|
||||
}
|
||||
@@ -183,7 +183,7 @@ impl<'a> BuffWriter<'a> {
|
||||
pub fn write_topic_filters_ref<const MAX: usize>(
|
||||
&mut self,
|
||||
sub: bool,
|
||||
len: usize,
|
||||
_len: usize,
|
||||
filters: &Vec<TopicFilter<'a>, MAX>,
|
||||
) -> Result<(), BufferError> {
|
||||
for filter in filters {
|
||||
|
||||
Reference in New Issue
Block a user