mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-18 08:32:11 +01:00
Add a writer1.available method.
This commit is contained in:
1 parent
ac405d485b
commit
c3ae0534df
6 files changed
+32
-8
No files matched your search
@@ -204,8 +204,11 @@ pri func decoder.decode_uncompressed?(dst writer1, src reader1)() {
|
||||
return error "internal error: inconsistent Huffman decoder state"
|
||||
}
|
||||
length -= n
|
||||
// TODO: distinguish between reads and writes.
|
||||
return suspension "short read"
|
||||
if in.dst.available() == 0 {
|
||||
return suspension "short write"
|
||||
} else {
|
||||
return suspension "short read"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user