From: Ian Jackson Date: Sun, 5 Jul 2020 12:48:31 +0000 (+0100) Subject: wip X-Git-Tag: otter-0.2.0~1449 X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=7ab4041aafdd67accc5a6eb55caa4c38d83cd640;p=otter.git wip --- diff --git a/src/bin/server.rs b/src/bin/server.rs index 353c4962..4169e06b 100644 --- a/src/bin/server.rs +++ b/src/bin/server.rs @@ -161,12 +161,12 @@ fn api_grab(form : Json) -> impl response::Responder<'static> { let update = PreparedUpdate { gen, client, - piece, + piece : form.piece, // split view needs modified value! cseq : form.cseq, json, }; let update = Arc::new(update); - // split vie wthing would go here + // split vie wthing would go here, see also update.piece p.gen_lastclient = gen; for (_tplayer, tplupdates) in &mut g.updates { tplupdates.log.push_back(update.clone()); diff --git a/src/global.rs b/src/global.rs index 8c22f6c5..6c5603b9 100644 --- a/src/global.rs +++ b/src/global.rs @@ -28,7 +28,7 @@ impl Client { pub struct PreparedUpdate { pub gen : Generation, pub client : ClientId, - pub piece : PieceId, + pub piece : VisiblePieceId, pub cseq : ClientSequence, pub json : String, } diff --git a/src/sse.rs b/src/sse.rs index 5f764aee..7e83ca5a 100644 --- a/src/sse.rs +++ b/src/sse.rs @@ -49,7 +49,7 @@ struct UpdateReader { #[derive(Serialize)] struct RecordedConfirmation { gen : Generation, - piece : PieceId, + piece : VisiblePieceId, cseq : ClientSequence, }