From b2235df0fe47cf596a3554ac0640c4890dcdb9dc Mon Sep 17 00:00:00 2001 From: Nicolas Stalder Date: Mon, 1 Feb 2021 01:36:51 +0100 Subject: [PATCH] Further cleanup; give up on heapless PR, external interchange/trussed --- Cargo.toml | 5 +++-- src/pipe.rs | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 20da254..447dcec 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,9 +8,10 @@ edition = "2018" [dependencies] ctap-types = { path = "../ctap-types" } delog = "0.1.0-alpha.3" -heapless = { version = "0.5.5" } +heapless = "0.5.6" +heapless-bytes = "0.1.1" hid-dispatch = { path = "../hid-dispatch" } -interchange = { path = "../interchange" } +interchange = "0.1.0" serde = { version = "1.0", default-features = false } usb-device = "0.2.3" diff --git a/src/pipe.rs b/src/pipe.rs index ade9bb1..eedb676 100644 --- a/src/pipe.rs +++ b/src/pipe.rs @@ -456,7 +456,7 @@ impl<'alloc, Bus: UsbBus> Pipe<'alloc, Bus> { _ => { self.interchange.request( - (request.command, heapless::ByteBuf::from_slice(&self.buffer[..request.length as usize]).unwrap()) + (request.command, heapless_bytes::Bytes::try_from_slice(&self.buffer[..request.length as usize]).unwrap()) ).unwrap(); self.state = State::WaitingOnAuthenticator(request); },