Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12:Update
libmspack
fix-division-by-zero.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File fix-division-by-zero.patch of Package libmspack
From b3102f4707a32d60514c06c399c3be4caffd7f25 Mon Sep 17 00:00:00 2001 From: Stuart Caie <kyzer@4u.net> Date: Sat, 17 Jan 2015 16:11:20 +0000 Subject: [PATCH] A reset interval of 0 is invalid --- libmspack/trunk/ChangeLog | 3 +++ libmspack/trunk/mspack/chmd.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) #diff --git a/libmspack/trunk/ChangeLog b/libmspack/trunk/ChangeLog #index ca402c6..dbd13dc 100644 #--- a/libmspack/trunk/ChangeLog #+++ b/libmspack/trunk/ChangeLog #@@ -3,6 +3,9 @@ # * GET_UTF8_CHAR(): Remove 5/6-byte encoding support and check decoded # chars are no more than U+10FFFF. # #+ * chmd_init_decomp(): A reset interval of 0 is invalid. Thanks to #+ Jakub Wilk for finding the issue and providing a sample and patch. #+ # 2015-01-15 Stuart Caie <kyzer@4u.net> # # * chmd_read_headers(): add a bounds check to prevent over-reading data, diff --git a/libmspack/trunk/mspack/chmd.c b/libmspack/trunk/mspack/chmd.c index 83624ae..c2257ae 100644 --- a/libmspack/trunk/mspack/chmd.c +++ b/libmspack/trunk/mspack/chmd.c @@ -1117,7 +1117,7 @@ static int chmd_init_decomp(struct mschm_decompressor_p *self, } /* validate reset_interval */ - if (reset_interval % LZX_FRAME_SIZE) { + if (reset_interval == 0 || reset_interval % LZX_FRAME_SIZE) { D(("bad controldata reset interval")) return self->error = MSPACK_ERR_DATAFORMAT; } -- 2.4.3
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor