]> icculus.org git repositories - icculus/xz.git/log
icculus/xz.git
16 years agoFree the allocated memory in lzmadec if debugging is
Lasse Collin [Tue, 15 Jan 2008 15:46:59 +0000 (17:46 +0200)]
Free the allocated memory in lzmadec if debugging is
enabled. This should make it possible to detect possible
memory leaks with Valgrind.

16 years agoFix memory leaks from test_block_header.c.
Lasse Collin [Tue, 15 Jan 2008 14:25:38 +0000 (16:25 +0200)]
Fix memory leaks from test_block_header.c.

16 years agoUse fastpos.h when encoding LZMA dictionary size in
Lasse Collin [Tue, 15 Jan 2008 12:23:35 +0000 (14:23 +0200)]
Use fastpos.h when encoding LZMA dictionary size in
Filter Flags encoder.

16 years agoRevised the fastpos code. It now uses the slightly faster
Lasse Collin [Tue, 15 Jan 2008 12:02:22 +0000 (14:02 +0200)]
Revised the fastpos code. It now uses the slightly faster
table-based version from LZMA SDK 4.57. This should be
fast on most systems.

A simpler and smaller alternative version is also provided.
On some CPUs this can be even a little faster than the
default table-based version (see comments in fastpos.h),
but on most systems the table-based code is faster.

16 years agoAdded bsr.h.
Lasse Collin [Tue, 15 Jan 2008 11:32:13 +0000 (13:32 +0200)]
Added bsr.h.

16 years agoFixed assembler detection in configure.ac, and added
Lasse Collin [Tue, 15 Jan 2008 11:29:14 +0000 (13:29 +0200)]
Fixed assembler detection in configure.ac, and added
detection for x86_64.

16 years agoOmit invalid space from printf() format string
Lasse Collin [Tue, 15 Jan 2008 10:20:41 +0000 (12:20 +0200)]
Omit invalid space from printf() format string
in price_table_gen.c.

16 years agoRemoved a few unused macros from lzma_common.h.
Lasse Collin [Tue, 15 Jan 2008 07:54:34 +0000 (09:54 +0200)]
Removed a few unused macros from lzma_common.h.

16 years agoFix a typo in lzma_encoder.c.
Lasse Collin [Tue, 15 Jan 2008 06:37:42 +0000 (08:37 +0200)]
Fix a typo in lzma_encoder.c.

16 years agoConvert bittree_get_price() and bittree_reverse_get_price()
Lasse Collin [Tue, 15 Jan 2008 06:36:25 +0000 (08:36 +0200)]
Convert bittree_get_price() and bittree_reverse_get_price()
from macros to inline functions.

16 years agoFix CRC code in case --enable-small is used.
Lasse Collin [Tue, 15 Jan 2008 05:44:59 +0000 (07:44 +0200)]
Fix CRC code in case --enable-small is used.

16 years agoFix typo in test_index.c.
Lasse Collin [Tue, 15 Jan 2008 05:41:39 +0000 (07:41 +0200)]
Fix typo in test_index.c.

16 years agoAdded precomputed range coder probability price table.
Lasse Collin [Tue, 15 Jan 2008 05:40:21 +0000 (07:40 +0200)]
Added precomputed range coder probability price table.

16 years agoRemove RC_BUFFER_SIZE from lzma_encoder_private.h
Lasse Collin [Mon, 14 Jan 2008 11:42:43 +0000 (13:42 +0200)]
Remove RC_BUFFER_SIZE from lzma_encoder_private.h
and replace it with a sanity check.

16 years agoMajor changes to LZ encoder, LZMA encoder, and range encoder.
Lasse Collin [Mon, 14 Jan 2008 11:39:54 +0000 (13:39 +0200)]
Major changes to LZ encoder, LZMA encoder, and range encoder.
These changes implement support for LZMA_SYNC_FLUSH in LZMA
encoder, and move the temporary buffer needed by range encoder
from lzma_range_encoder structure to lzma_lz_encoder.

16 years agoAdded one assert() to process.c of the command line tool.
Lasse Collin [Mon, 14 Jan 2008 11:34:29 +0000 (13:34 +0200)]
Added one assert() to process.c of the command line tool.

16 years agoDon't use coder->lz.stream_end_was_reached in assertions
Lasse Collin [Mon, 14 Jan 2008 10:09:52 +0000 (12:09 +0200)]
Don't use coder->lz.stream_end_was_reached in assertions
in match_c.h.

16 years agoIn lzma_read_match_distances(), don't use
Lasse Collin [Mon, 14 Jan 2008 10:08:02 +0000 (12:08 +0200)]
In lzma_read_match_distances(), don't use
coder->lz.stream_end_was_reached. That variable
will be removed, and the check isn't required anyway.
Rearrange the check so that it doesn't make one to
think that there could be an integer overflow.

16 years agoSmall LZMA_SYNC_FLUSH fixes to Block and Single-Stream encoders.
Lasse Collin [Mon, 14 Jan 2008 09:56:41 +0000 (11:56 +0200)]
Small LZMA_SYNC_FLUSH fixes to Block and Single-Stream encoders.

16 years agoMore fixes to LZMA decoder's flush marker handling.
Lasse Collin [Mon, 14 Jan 2008 09:54:56 +0000 (11:54 +0200)]
More fixes to LZMA decoder's flush marker handling.

16 years agoEliminate lzma_lz_encoder.must_move_pos. It's needed
Lasse Collin [Thu, 10 Jan 2008 15:13:42 +0000 (17:13 +0200)]
Eliminate lzma_lz_encoder.must_move_pos. It's needed
only in one place which isn't performance criticial.

16 years agoDefine HAVE_ASM_X86 when x86 assembler optimizations are
Lasse Collin [Wed, 9 Jan 2008 18:05:57 +0000 (20:05 +0200)]
Define HAVE_ASM_X86 when x86 assembler optimizations are
used. This #define will be useful for inline assembly.

16 years agoAdded good-single-none-empty_3.lzma and
Lasse Collin [Wed, 9 Jan 2008 10:06:46 +0000 (12:06 +0200)]
Added good-single-none-empty_3.lzma and
bad-single-none-empty.lzma.

16 years agoTake advantage of return_if_error() in block_decoder.c.
Lasse Collin [Tue, 8 Jan 2008 21:11:59 +0000 (23:11 +0200)]
Take advantage of return_if_error() in block_decoder.c.

16 years agoUpdated tests/files/README.
Lasse Collin [Tue, 8 Jan 2008 21:10:57 +0000 (23:10 +0200)]
Updated tests/files/README.

16 years agoAdded test files with empty Compressed Data.
Lasse Collin [Tue, 8 Jan 2008 21:05:40 +0000 (23:05 +0200)]
Added test files with empty Compressed Data.

16 years agoFix decoding of Blocks that have only Block Header.
Lasse Collin [Tue, 8 Jan 2008 20:58:42 +0000 (22:58 +0200)]
Fix decoding of Blocks that have only Block Header.

16 years agoAdded good-single-subblock_implicit.lzma.
Lasse Collin [Tue, 8 Jan 2008 20:27:46 +0000 (22:27 +0200)]
Added good-single-subblock_implicit.lzma.

16 years agoDisable CRC32 from Block Headers when --check=none
Lasse Collin [Tue, 8 Jan 2008 16:50:30 +0000 (18:50 +0200)]
Disable CRC32 from Block Headers when --check=none
has been specified.

16 years agoFixed encoding of empty files. Arguments to is_size_valid()
Lasse Collin [Tue, 8 Jan 2008 11:36:29 +0000 (13:36 +0200)]
Fixed encoding of empty files. Arguments to is_size_valid()
were in wrong order in block_encoder.c.

16 years agoAdded a few test files.
Lasse Collin [Tue, 8 Jan 2008 11:35:36 +0000 (13:35 +0200)]
Added a few test files.

16 years agoAvoid using ! in test_files.sh, because that doesn't work
Lasse Collin [Tue, 8 Jan 2008 10:29:58 +0000 (12:29 +0200)]
Avoid using ! in test_files.sh, because that doesn't work
with some ancient /bin/sh versions.

16 years agoMore pre-C99 inttypes.h compatibility fixes. Now the code
Lasse Collin [Mon, 7 Jan 2008 22:48:30 +0000 (00:48 +0200)]
More pre-C99 inttypes.h compatibility fixes. Now the code
should work even if the system has no inttypes.h.

16 years agoUpdated fi.po although it's currently pretty much crap.
Lasse Collin [Mon, 7 Jan 2008 21:25:32 +0000 (23:25 +0200)]
Updated fi.po although it's currently pretty much crap.

16 years agoTest for $GCC = yes instead of if it is non-empty. This
Lasse Collin [Mon, 7 Jan 2008 21:14:25 +0000 (23:14 +0200)]
Test for $GCC = yes instead of if it is non-empty. This
way it is possible to use ac_cv_c_compiler_gnu=no to
force configure to think it is using non-GNU C compiler.

16 years agoAdded test_files.sh to tests/Makefile.am so it gets
Lasse Collin [Mon, 7 Jan 2008 19:49:41 +0000 (21:49 +0200)]
Added test_files.sh to tests/Makefile.am so it gets
included in the tarball with "make dist".

16 years agoCosmetic edit to test_files.sh.
Lasse Collin [Mon, 7 Jan 2008 16:22:24 +0000 (18:22 +0200)]
Cosmetic edit to test_files.sh.

16 years agoAdded tests/files/README.
Lasse Collin [Mon, 7 Jan 2008 16:09:44 +0000 (18:09 +0200)]
Added tests/files/README.

16 years agoTell in COPYING that everything in tests/files is
Lasse Collin [Mon, 7 Jan 2008 12:20:57 +0000 (14:20 +0200)]
Tell in COPYING that everything in tests/files is
public domain.

16 years agoCleaned up the tests/files directory.
Lasse Collin [Mon, 7 Jan 2008 12:19:05 +0000 (14:19 +0200)]
Cleaned up the tests/files directory.

16 years agoAdded test_files.sh to test decoding of the files in
Lasse Collin [Mon, 7 Jan 2008 11:49:19 +0000 (13:49 +0200)]
Added test_files.sh to test decoding of the files in
the tests/files directory. It doesn't test the malicious
files yet.

16 years agoUpdated README regarding the assembler optimizations.
Lasse Collin [Mon, 7 Jan 2008 09:23:13 +0000 (11:23 +0200)]
Updated README regarding the assembler optimizations.

16 years agoUpdated THANKS.
Lasse Collin [Mon, 7 Jan 2008 08:58:00 +0000 (10:58 +0200)]
Updated THANKS.

16 years agoCosmetic changes to configure.ac.
Lasse Collin [Sun, 6 Jan 2008 19:47:17 +0000 (21:47 +0200)]
Cosmetic changes to configure.ac.

16 years agoAutomatically disable assembler code on Darwin x86.
Lasse Collin [Sun, 6 Jan 2008 17:46:38 +0000 (19:46 +0200)]
Automatically disable assembler code on Darwin x86.
Darwin has different ABI than GNU+Linux and Solaris,
thus the assembler code doesn't assemble on Darwin.

16 years agoWith printf(), use PRIu64 with a cast to uint64_t instead
Lasse Collin [Sun, 6 Jan 2008 17:45:27 +0000 (19:45 +0200)]
With printf(), use PRIu64 with a cast to uint64_t instead
of %zu, because some pre-C99 libc versions don't support %zu.

16 years agoIntroduced compatibility with systems that have pre-C99
Lasse Collin [Sun, 6 Jan 2008 14:27:41 +0000 (16:27 +0200)]
Introduced compatibility with systems that have pre-C99
or no inttypes.h. This is useful when the compiler has
good enough support for C99, but libc headers don't.

Changed liblzma API so that sys/types.h and inttypes.h
have to be #included before #including lzma.h. On systems
that don't have C99 inttypes.h, it's the problem of the
applications to provide the required types and macros
before #including lzma.h.

If lzma.h defined the missing types and macros, it could
conflict with third-party applications whose configure
has detected that the types are missing and defined them
in config.h already. An alternative would have been
introducing lzma_uint32 and similar types, but that would
just be an extra pain on modern systems.

16 years agoFix typo in comment (INT64_MAX -> UINT64_MAX).
Lasse Collin [Sat, 5 Jan 2008 17:57:00 +0000 (19:57 +0200)]
Fix typo in comment (INT64_MAX -> UINT64_MAX).

16 years agoRearranged testing of GCC-specific flags.
Lasse Collin [Sat, 5 Jan 2008 17:42:04 +0000 (19:42 +0200)]
Rearranged testing of GCC-specific flags.

16 years agoAnother bug fix for flush marker detection.
Lasse Collin [Fri, 4 Jan 2008 23:20:24 +0000 (01:20 +0200)]
Another bug fix for flush marker detection.

16 years agoFix stupid bugs in flush marker detection.
Lasse Collin [Fri, 4 Jan 2008 19:37:01 +0000 (21:37 +0200)]
Fix stupid bugs in flush marker detection.

16 years agoAdded support for flush marker, which will be in files
Lasse Collin [Fri, 4 Jan 2008 19:30:33 +0000 (21:30 +0200)]
Added support for flush marker, which will be in files
that use LZMA_SYNC_FLUSH with encoder (not implemented
yet). This is a new feature in the raw LZMA format,
which isn't supported by old decoders. This shouldn't
be a problem in practice, since lzma_alone_encoder()
will not allow LZMA_SYNC_FLUSH, and thus not allow
creating files on decodable with old decoders.

Made lzma_decoder.c to require tab width of 4 characters
if one wants to fit the code in 80 columns. This makes
the code easier to read.

16 years agoMoved range decoder initialization (reading the first
Lasse Collin [Fri, 4 Jan 2008 18:45:05 +0000 (20:45 +0200)]
Moved range decoder initialization (reading the first
five input bytes) from LZMA decoder to range decoder
header. Did the same for decoding of direct bits.

16 years agoAdded a note to README that --disable-assembler
Lasse Collin [Fri, 14 Dec 2007 09:15:21 +0000 (11:15 +0200)]
Added a note to README that --disable-assembler
must be used on Darwin.

16 years agoUse the filename suffix .S instead of .s for assembler files
Lasse Collin [Fri, 14 Dec 2007 08:07:10 +0000 (10:07 +0200)]
Use the filename suffix .S instead of .s for assembler files
so that the preprocessor removes the /* */ style comments,
which are not supported by some non-GNU assemblers (Solaris)
that otherwise work with this code.

16 years agoFixed wrong symbol name in crc64_x86.s.
Lasse Collin [Fri, 14 Dec 2007 07:59:05 +0000 (09:59 +0200)]
Fixed wrong symbol name in crc64_x86.s.

16 years agoUse .globl instead of .global in x86 assembler code for
Lasse Collin [Fri, 14 Dec 2007 07:53:24 +0000 (09:53 +0200)]
Use .globl instead of .global in x86 assembler code for
better portability. Still needs fixing the commenting.

16 years agoFixed a few short options that take an argument.
Lasse Collin [Thu, 13 Dec 2007 18:14:37 +0000 (20:14 +0200)]
Fixed a few short options that take an argument.
short_opts[] was missing colons to indicate
required argument. Thanks to Fabio Pedretti for
the bug report.

16 years agoRemoved uncompressed size tracking from Delta encoder too.
Lasse Collin [Tue, 11 Dec 2007 15:08:04 +0000 (17:08 +0200)]
Removed uncompressed size tracking from Delta encoder too.

16 years agoRemove uncompressed size tracking from the filter encoders.
Lasse Collin [Tue, 11 Dec 2007 14:49:19 +0000 (16:49 +0200)]
Remove uncompressed size tracking from the filter encoders.
It's not strictly needed there, and just complicates the
code. LZ encoder never even had this feature.

The primary reason to have uncompressed size tracking in
filter encoders was validating that the application
doesn't give different amount of input that it had
promised. A side effect was to validate internal workings
of liblzma.

Uncompressed size tracking is still present in the Block
encoder. Maybe it should be added to LZMA_Alone and raw
encoders too. It's simpler to have one coder just to
validate the uncompressed size instead of having it
in every filter.

16 years agoGet rid of no-NLS gnulib. I don't know how to get it
Lasse Collin [Tue, 11 Dec 2007 12:10:53 +0000 (14:10 +0200)]
Get rid of no-NLS gnulib. I don't know how to get it
working with Automake. People who want smaller lzmadec
should use --disable-nls on non-GNU systems.

16 years agoFixed a typo in tests/Makefile.am which prevented
Lasse Collin [Tue, 11 Dec 2007 12:09:35 +0000 (14:09 +0200)]
Fixed a typo in tests/Makefile.am which prevented
building the tests if gnulib was needed.

16 years agoFixed wrong type of flags_size in Subblock encoder.
Lasse Collin [Tue, 11 Dec 2007 09:18:58 +0000 (11:18 +0200)]
Fixed wrong type of flags_size in Subblock encoder.

16 years agoBumped version number to 4.42.3alpha.
Lasse Collin [Mon, 10 Dec 2007 18:44:16 +0000 (20:44 +0200)]
Bumped version number to 4.42.3alpha.

16 years agoDisabled some unneeded warnings and made "make dist" work. v4.42.2alpha
Lasse Collin [Mon, 10 Dec 2007 13:02:50 +0000 (15:02 +0200)]
Disabled some unneeded warnings and made "make dist" work.

16 years agoAdded LZMA_SYNC_FLUSH support to the Copy filter.
Lasse Collin [Sun, 9 Dec 2007 19:43:15 +0000 (21:43 +0200)]
Added LZMA_SYNC_FLUSH support to the Copy filter.

16 years agoAdded missing LZMA_API to the C versions of the CRC functions.
Lasse Collin [Sun, 9 Dec 2007 15:14:07 +0000 (17:14 +0200)]
Added missing LZMA_API to the C versions of the CRC functions.
The x86 assembler versions were already OK.

16 years ago* tests/test_block_header.c (test3): Remove duplicate initializer.
Jim Meyering [Sun, 9 Dec 2007 14:34:25 +0000 (15:34 +0100)]
* tests/test_block_header.c (test3): Remove duplicate initializer.

16 years agoTake advantage of return_if_error() macro in more places.
Lasse Collin [Sun, 9 Dec 2007 15:06:45 +0000 (17:06 +0200)]
Take advantage of return_if_error() macro in more places.
Cleaned Subblock filter's initialization code too.

16 years agoAdded a bunch of .lzma test files.
Lasse Collin [Sun, 9 Dec 2007 10:13:01 +0000 (12:13 +0200)]
Added a bunch of .lzma test files.

16 years agoRe-enabled the security checks in Subblock decoder
Lasse Collin [Sun, 9 Dec 2007 09:24:48 +0000 (11:24 +0200)]
Re-enabled the security checks in Subblock decoder
that were disabled for debugging reasons.

16 years agoFixed the tests to build with -Werror.
Lasse Collin [Sun, 9 Dec 2007 09:03:28 +0000 (11:03 +0200)]
Fixed the tests to build with -Werror.

16 years agoImported to git.
Lasse Collin [Sat, 8 Dec 2007 22:42:33 +0000 (00:42 +0200)]
Imported to git.