~sircmpwn/hare-compress

7130e452ddc75e7f01a6ccf57afafda069dd53ec — Ember Sawady 1 year, 6 months ago ad504ee
compress::flate: fix incorrect assertion
1 files changed, 1 insertions(+), 1 deletions(-)

M compress/flate/inflate.ha
M compress/flate/inflate.ha => compress/flate/inflate.ha +1 -1
@@ 142,7 142,7 @@ fn put(d: *decompressor, b: u8...) void = {
	b = b[n..];
	d.head += n;
	for (let s = b; len(s) != 0) {
		assert(len(d.buf) == BUFSIZE);
		assert(len(d.hist) == BUFSIZE);
		const toput = if (d.head + len(s) > len(d.hist))
			len(d.hist) - d.head else len(s);
		d.hist[d.head..d.head + toput] = s[..toput];