]> icculus.org git repositories - icculus/xz.git/commit
BCJ filters: Reject invalid start offsets with LZMA_OPTIONS_ERROR.
authorLasse Collin <lasse.collin@tukaani.org>
Fri, 10 Jul 2009 08:39:38 +0000 (11:39 +0300)
committerLasse Collin <lasse.collin@tukaani.org>
Fri, 10 Jul 2009 08:39:38 +0000 (11:39 +0300)
commitcd69a5a6c16c289f6f8e2823b03c72289472270f
treea7c807f5c1a2e6d3ce345e6fbc6dab17430e9dc0
parenteed9953732b801f6c97317fb3160445a8754180b
BCJ filters: Reject invalid start offsets with LZMA_OPTIONS_ERROR.

This is a quick and slightly dirty fix to make the code
conform to the latest file format specification. Without
this patch, it's possible to make corrupt files by
specifying start offset that is not a multiple of the
filter's alignment. Custom start offset is almost never
used, so this was only a minor bug.

The xz command line tool doesn't validate the start offset,
so one will get a bit unclear error message if trying to use
an invalid start offset.
src/liblzma/simple/arm.c
src/liblzma/simple/armthumb.c
src/liblzma/simple/ia64.c
src/liblzma/simple/powerpc.c
src/liblzma/simple/simple_coder.c
src/liblzma/simple/simple_private.h
src/liblzma/simple/sparc.c
src/liblzma/simple/x86.c