diff options
author | Kostya Shishkov <kostya.shishkov@gmail.com> | 2020-04-15 11:51:21 +0200 |
---|---|---|
committer | Kostya Shishkov <kostya.shishkov@gmail.com> | 2020-04-15 11:51:31 +0200 |
commit | ed6c9f8a7b4c723b02361bf75fdccdc40eb427cc (patch) | |
tree | 9383bb6ce16addb700fd283bf85505e9c59efbae | |
parent | 73a1eecd8aa9c657ab70e2e4d27a62dd89b290f7 (diff) | |
download | nihav-ed6c9f8a7b4c723b02361bf75fdccdc40eb427cc.tar.gz |
vmd: raise unpacked buffer size to a factor four
-rw-r--r-- | nihav-game/src/codecs/vmd.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/nihav-game/src/codecs/vmd.rs b/nihav-game/src/codecs/vmd.rs index 41bfad9..b81b4f5 100644 --- a/nihav-game/src/codecs/vmd.rs +++ b/nihav-game/src/codecs/vmd.rs @@ -236,7 +236,7 @@ impl NADecoder for VMDVideoDecoder { if let Some(ref edata) = info.get_extradata() { validate!(edata.len() == 0x330); let unp_size = read_u32le(&edata[800..])? as usize; - validate!(unp_size < self.width * self.height * 3 + 64); // just for sanity + validate!(unp_size < self.width * self.height * 4 + 64); // just for sanity self.buf.resize(unp_size, 0); for i in 0..768 { let el = edata[28 + i]; |