mirror of
https://github.com/kasmtech/KasmVNC.git
synced 2024-11-23 00:23:13 +01:00
Handle errors from zlib/pako
This commit is contained in:
parent
b690ae4c2d
commit
dbe2930758
@ -35,7 +35,10 @@ export default class Inflate {
|
||||
|
||||
this.strm.avail_out = this.chunkSize;
|
||||
|
||||
inflate(this.strm, 0); // Flush argument not used.
|
||||
let ret = inflate(this.strm, 0); // Flush argument not used.
|
||||
if (ret < 0) {
|
||||
throw new Error("zlib inflate failed");
|
||||
}
|
||||
|
||||
if (this.strm.next_out != expected) {
|
||||
throw new Error("Incomplete zlib block");
|
||||
|
Loading…
Reference in New Issue
Block a user