From ceec9b97971cc0f66a20b10051498b80fd4d6348 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 27 Jul 2020 00:27:51 +0100 Subject: [PATCH] piece insert sort of works but js doesn't do the thing --- src/cmdlistener.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/cmdlistener.rs b/src/cmdlistener.rs index 8a2167a4..948986e6 100644 --- a/src/cmdlistener.rs +++ b/src/cmdlistener.rs @@ -199,7 +199,7 @@ fn do_authorise_scope(cs: &CommandStream, wanted: &ManagementScope) #[throws(ME)] fn execute(cs: &mut CommandStream, cmd: MgmtCommand) -> MgmtResponse { -// use MgmtError::*; + eprintln!("{:?} executing {:?}", &cs.desc, &cmd); match cmd { Noop { } => Fine { }, @@ -266,7 +266,7 @@ fn execute(cs: &mut CommandStream, cmd: MgmtCommand) -> MgmtResponse { #[derive(Debug,Default)] struct UpdateHandlerBulk { - pieces : SecondarySlotMap>, + pieces : slotmap::SparseSecondaryMap>, } #[derive(Debug)] @@ -301,7 +301,7 @@ impl UpdateHandler { ( _ , _ ) => Some( Modify(()) ), }; match ne { - Some(ne) => { bulk.pieces[upiece] = ne; }, + Some(ne) => { bulk.pieces.insert(upiece, ne); }, None => { bulk.pieces.remove(upiece); }, }; } -- 2.30.2