summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-11-20 23:06:52 -0300
committerGabriel Schneider <[email protected]>2026-11-21 00:59:00 -0300
commitdac87eaa1d57acfc5b2dd8427e7fbacfe065e613 (patch)
tree491cfc78149e6983a9a98dd8b2944ddea78927d7 /test
parent1388d776ae759796884b9faa106b1c9c222eefa9 (diff)
downloadpardes-dac87eaa1d57acfc5b2dd8427e7fbacfe065e613.tar.gz
pardes-dac87eaa1d57acfc5b2dd8427e7fbacfe065e613.zip
soak: a cut client's queue stamped from within it: scrt-6 panicked in Soak.stamp ('start index 67100408 is larger than end index 31'): the session cut the far client off past its limit (replica.zig Peer.send), which empties its queue for the 31 bytes of its refusal, while the soak's mark still stood 64 MiB into the old one (the trace's 11 KB digests had swelled that queue); the mark is kept within the queue; the gate after it: bytes --seeds 8 --witness 5 of 5, seed 0 at 30 ms 40 of 40, screen-state (traced) 10 of 10
Co-Authored-By: Claude Opus <[email protected]> Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'test')
-rw-r--r--test/replicas.zig3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/replicas.zig b/test/replicas.zig
index c0df99a1..e035cd81 100644
--- a/test/replicas.zig
+++ b/test/replicas.zig
@@ -1462,7 +1462,8 @@ const Soak = struct {
/// from them (`joined`: in process, both read one).
fn stamp(s: *Soak, cl: *Client, peer: *replica.Peer) void {
const out = peer.out.items;
- var at = cl.marked;
+ // A cut (Peer.send, past its limit) empties the queue for its words.
+ var at = @min(cl.marked, out.len);
while (pardes.wire.framed(out[at..]) catch null) |f| : (at += f.total) {
if (f.tag != @backingInt(pardes.wire.ServerTag.unit)) continue;
const head = at + f.total - f.payload.len;