Drop the upper limit on lzma compression window on 64 bit. It is not necessary.

zpaq will fail with windows bigger than 600MB on 32 bit due to failing testing the 3* malloc test, so limit it to 600MB as well as lzma on 32 bit.
This commit is contained in:
Con Kolivas 2010-11-07 01:57:23 +11:00
parent b8528abee9
commit ead0e54182
3 changed files with 9 additions and 11 deletions

View file

@ -583,15 +583,10 @@ void *open_stream_out(int f, int n, i64 limit)
however, the larger the buffer, the better the compression so we
make it as large as the window up to the limit the compressor
will take */
if (LZMA_COMPRESS) {
if (sizeof(long) == 4) {
/* Largest window supported on lzma 32bit is 600MB */
if (!cwindow || cwindow > 6)
cwindow = 6;
}
/* Largest window supported on lzma 64bit is 4GB */
if (!cwindow || cwindow > 40)
cwindow = 40;
if (BITS32) {
/* Largest window supported on 32bit is 600MB */
if (!cwindow || cwindow > 6)
cwindow = 6;
}
if (LZMA_COMPRESS || ZPAQ_COMPRESS)