Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
HardenedBSD
HardenedBSD
Commits
fb69e223
Commit
fb69e223
authored
Aug 11, 2019
by
Xin LI
Browse files
Vendor import bzip2 -- upgrade to version 1.0.8.
parent
7897e222
Changes
20
Hide whitespace changes
Inline
Side-by-side
CHANGES
View file @
fb69e223
...
@@ -2,8 +2,8 @@
...
@@ -2,8 +2,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -338,3 +338,19 @@ Security fix only. Fixes CERT-FI 20469 as it applies to bzip2.
...
@@ -338,3 +338,19 @@ Security fix only. Fixes CERT-FI 20469 as it applies to bzip2.
* bzip2recover: Fix use after free issue with outFile (CVE-2016-3189)
* bzip2recover: Fix use after free issue with outFile (CVE-2016-3189)
* Make sure nSelectors is not out of range (CVE-2019-12900)
* Make sure nSelectors is not out of range (CVE-2019-12900)
1.0.8 (13 Jul 19)
~~~~~~~~~~~~~~~~~
* Accept as many selectors as the file format allows.
This relaxes the fix for CVE-2019-12900 from 1.0.7
so that bzip2 allows decompression of bz2 files that
use (too) many selectors again.
* Fix handling of large (> 4GB) files on Windows.
* Cleanup of bzdiff and bzgrep scripts so they don't use
any bash extensions and handle multiple archives correctly.
* There is now a bz2-files testsuite at
https://sourceware.org/git/bzip2-tests.git
LICENSE
View file @
fb69e223
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
--------------------------------------------------------------------------
--------------------------------------------------------------------------
This program, "bzip2", the associated library "libbzip2", and all
This program, "bzip2", the associated library "libbzip2", and all
documentation, are copyright (C) 1996-201
0
Julian R Seward. All
documentation, are copyright (C) 1996-201
9
Julian R Seward. All
rights reserved.
rights reserved.
Redistribution and use in source and binary forms, with or without
Redistribution and use in source and binary forms, with or without
...
@@ -37,6 +37,6 @@ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
...
@@ -37,6 +37,6 @@ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Julian Seward, jseward@acm.org
Julian Seward, jseward@acm.org
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
--------------------------------------------------------------------------
--------------------------------------------------------------------------
Makefile
View file @
fb69e223
...
@@ -2,8 +2,8 @@
...
@@ -2,8 +2,8 @@
# This file is part of bzip2/libbzip2, a program and library for
# This file is part of bzip2/libbzip2, a program and library for
# lossless, block-sorting data compression.
# lossless, block-sorting data compression.
#
#
# bzip2/libbzip2 version 1.0.
6
of
6 September
201
0
# bzip2/libbzip2 version 1.0.
8
of
13 July
201
9
# Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
# Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
#
#
# Please read the WARNING, DISCLAIMER and PATENTS sections in the
# Please read the WARNING, DISCLAIMER and PATENTS sections in the
# README file.
# README file.
...
@@ -137,7 +137,7 @@ bzip2recover.o: bzip2recover.c
...
@@ -137,7 +137,7 @@ bzip2recover.o: bzip2recover.c
distclean
:
clean
distclean
:
clean
rm
-f
manual.ps manual.html manual.pdf
rm
-f
manual.ps manual.html manual.pdf
DISTNAME
=
bzip2-1.0.
7
DISTNAME
=
bzip2-1.0.
8
dist
:
check manual
dist
:
check manual
rm
-f
$(DISTNAME)
rm
-f
$(DISTNAME)
ln
-s
-f
.
$(DISTNAME)
ln
-s
-f
.
$(DISTNAME)
...
...
Makefile-libbz2_so
View file @
fb69e223
# This Makefile builds a shared version of the library,
# This Makefile builds a shared version of the library,
# libbz2.so.1.0.
7
, with soname libbz2.so.1.0,
# libbz2.so.1.0.
8
, with soname libbz2.so.1.0,
# at least on x86-Linux (RedHat 7.2),
# at least on x86-Linux (RedHat 7.2),
# with gcc-2.96 20000731 (Red Hat Linux 7.1 2.96-98).
# with gcc-2.96 20000731 (Red Hat Linux 7.1 2.96-98).
# Please see the README file for some important info
# Please see the README file for some important info
...
@@ -10,8 +10,8 @@
...
@@ -10,8 +10,8 @@
# This file is part of bzip2/libbzip2, a program and library for
# This file is part of bzip2/libbzip2, a program and library for
# lossless, block-sorting data compression.
# lossless, block-sorting data compression.
#
#
# bzip2/libbzip2 version 1.0.
6
of
6 September
201
0
# bzip2/libbzip2 version 1.0.
8
of
13 July
201
9
# Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
# Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
#
#
# Please read the WARNING, DISCLAIMER and PATENTS sections in the
# Please read the WARNING, DISCLAIMER and PATENTS sections in the
# README file.
# README file.
...
@@ -35,13 +35,13 @@ OBJS= blocksort.o \
...
@@ -35,13 +35,13 @@ OBJS= blocksort.o \
bzlib.o
bzlib.o
all: $(OBJS)
all: $(OBJS)
$(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.
7
$(OBJS)
$(CC) -shared -Wl,-soname -Wl,libbz2.so.1.0 -o libbz2.so.1.0.
8
$(OBJS)
$(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.
7
$(CC) $(CFLAGS) -o bzip2-shared bzip2.c libbz2.so.1.0.
8
rm -f libbz2.so.1.0
rm -f libbz2.so.1.0
ln -s libbz2.so.1.0.
7
libbz2.so.1.0
ln -s libbz2.so.1.0.
8
libbz2.so.1.0
clean:
clean:
rm -f $(OBJS) bzip2.o libbz2.so.1.0.
7
libbz2.so.1.0 bzip2-shared
rm -f $(OBJS) bzip2.o libbz2.so.1.0.
8
libbz2.so.1.0 bzip2-shared
blocksort.o: blocksort.c
blocksort.o: blocksort.c
$(CC) $(CFLAGS) -c blocksort.c
$(CC) $(CFLAGS) -c blocksort.c
...
...
README
View file @
fb69e223
...
@@ -6,8 +6,8 @@ This version is fully compatible with the previous public releases.
...
@@ -6,8 +6,8 @@ This version is fully compatible with the previous public releases.
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in this file.
Please read the WARNING, DISCLAIMER and PATENTS sections in this file.
...
@@ -165,8 +165,8 @@ WHAT'S NEW IN 1.0.x ?
...
@@ -165,8 +165,8 @@ WHAT'S NEW IN 1.0.x ?
See the CHANGES file.
See the CHANGES file.
I hope you find bzip2 useful. Feel free to contact
me
at
I hope you find bzip2 useful. Feel free to contact
the developers
at
jseward@acm
.org
bzip2-devel@sourceware
.org
if you have any suggestions or queries. Many people mailed me with
if you have any suggestions or queries. Many people mailed me with
comments, suggestions and patches after the releases of bzip-0.15,
comments, suggestions and patches after the releases of bzip-0.15,
bzip-0.21, and bzip2 versions 0.1pl2, 0.9.0, 0.9.5, 1.0.0, 1.0.1,
bzip-0.21, and bzip2 versions 0.1pl2, 0.9.0, 0.9.5, 1.0.0, 1.0.1,
...
@@ -193,3 +193,4 @@ Cambridge, UK.
...
@@ -193,3 +193,4 @@ Cambridge, UK.
10 December 2007 (bzip2, version 1.0.5)
10 December 2007 (bzip2, version 1.0.5)
6 Sept 2010 (bzip2, version 1.0.6)
6 Sept 2010 (bzip2, version 1.0.6)
27 June 2019 (bzip2, version 1.0.7)
27 June 2019 (bzip2, version 1.0.7)
13 July 2019 (bzip2, version 1.0.8)
README.COMPILATION.PROBLEMS
View file @
fb69e223
...
@@ -2,8 +2,8 @@
...
@@ -2,8 +2,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
blocksort.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
bzip2.1
View file @
fb69e223
.PU
.PU
.TH bzip2 1
.TH bzip2 1
.SH NAME
.SH NAME
bzip2, bunzip2 \- a block-sorting file compressor, v1.0.
7
bzip2, bunzip2 \- a block-sorting file compressor, v1.0.
8
.br
.br
bzcat \- decompresses files to stdout
bzcat \- decompresses files to stdout
.br
.br
...
@@ -405,7 +405,7 @@ I/O error messages are not as helpful as they could be.
...
@@ -405,7 +405,7 @@ I/O error messages are not as helpful as they could be.
tries hard to detect I/O errors and exit cleanly, but the details of
tries hard to detect I/O errors and exit cleanly, but the details of
what the problem is sometimes seem rather misleading.
what the problem is sometimes seem rather misleading.
This manual page pertains to version 1.0.
7
of
This manual page pertains to version 1.0.
8
of
.I bzip2.
.I bzip2.
Compressed data created by this version is entirely forwards and
Compressed data created by this version is entirely forwards and
backwards compatible with the previous public releases, versions
backwards compatible with the previous public releases, versions
...
...
bzip2.c
View file @
fb69e223
...
@@ -7,8 +7,8 @@
...
@@ -7,8 +7,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -128,12 +128,12 @@
...
@@ -128,12 +128,12 @@
#if BZ_LCCWIN32
#if BZ_LCCWIN32
# include <io.h>
# include <io.h>
# include <fcntl.h>
# include <fcntl.h>
# include <sys
\
stat.h>
# include <sys
/
stat.h>
# define NORETURN
/**/
# define NORETURN
/**/
# define PATH_SEP '\\'
# define PATH_SEP '\\'
# define MY_LSTAT _stat
# define MY_LSTAT _stat
i64
# define MY_STAT _stat
# define MY_STAT _stat
i64
# define MY_S_ISREG(x) ((x) & _S_IFREG)
# define MY_S_ISREG(x) ((x) & _S_IFREG)
# define MY_S_ISDIR(x) ((x) & _S_IFDIR)
# define MY_S_ISDIR(x) ((x) & _S_IFDIR)
...
@@ -748,8 +748,8 @@ void panic ( const Char* s )
...
@@ -748,8 +748,8 @@ void panic ( const Char* s )
fprintf
(
stderr
,
fprintf
(
stderr
,
"
\n
%s: PANIC -- internal consistency error:
\n
"
"
\n
%s: PANIC -- internal consistency error:
\n
"
"
\t
%s
\n
"
"
\t
%s
\n
"
"
\t
This is a BUG. Please report it to
me at
:
\n
"
"
\t
This is a BUG. Please report it to:
\n
"
"
\t
jseward@acm
.org
\n
"
,
"
\t
bzip2-devel@sourceware
.org
\n
"
,
progName
,
s
);
progName
,
s
);
showFileNames
();
showFileNames
();
cleanUpAndFail
(
3
);
cleanUpAndFail
(
3
);
...
@@ -829,7 +829,7 @@ void mySIGSEGVorSIGBUScatcher ( IntNative n )
...
@@ -829,7 +829,7 @@ void mySIGSEGVorSIGBUScatcher ( IntNative n )
" The user's manual, Section 4.3, has more info on (1) and (2).
\n
"
" The user's manual, Section 4.3, has more info on (1) and (2).
\n
"
"
\n
"
"
\n
"
" If you suspect this is a bug in bzip2, or are unsure about (1)
\n
"
" If you suspect this is a bug in bzip2, or are unsure about (1)
\n
"
" or (2), feel free to report it to
me at: jseward@acm
.org.
\n
"
" or (2), feel free to report it to
: bzip2-devel@sourceware
.org.
\n
"
" Section 4.3 of the user's manual describes the info a useful
\n
"
" Section 4.3 of the user's manual describes the info a useful
\n
"
" bug report should have. If the manual is available on your
\n
"
" bug report should have. If the manual is available on your
\n
"
" system, please try and read it before mailing me. If you don't
\n
"
" system, please try and read it before mailing me. If you don't
\n
"
...
@@ -852,7 +852,7 @@ void mySIGSEGVorSIGBUScatcher ( IntNative n )
...
@@ -852,7 +852,7 @@ void mySIGSEGVorSIGBUScatcher ( IntNative n )
" The user's manual, Section 4.3, has more info on (2) and (3).
\n
"
" The user's manual, Section 4.3, has more info on (2) and (3).
\n
"
"
\n
"
"
\n
"
" If you suspect this is a bug in bzip2, or are unsure about (2)
\n
"
" If you suspect this is a bug in bzip2, or are unsure about (2)
\n
"
" or (3), feel free to report it to
me at: jseward@acm
.org.
\n
"
" or (3), feel free to report it to
: bzip2-devel@sourceware
.org.
\n
"
" Section 4.3 of the user's manual describes the info a useful
\n
"
" Section 4.3 of the user's manual describes the info a useful
\n
"
" bug report should have. If the manual is available on your
\n
"
" bug report should have. If the manual is available on your
\n
"
" system, please try and read it before mailing me. If you don't
\n
"
" system, please try and read it before mailing me. If you don't
\n
"
...
@@ -1605,7 +1605,7 @@ void license ( void )
...
@@ -1605,7 +1605,7 @@ void license ( void )
"bzip2, a block-sorting file compressor. "
"bzip2, a block-sorting file compressor. "
"Version %s.
\n
"
"Version %s.
\n
"
"
\n
"
"
\n
"
" Copyright (C) 1996-201
0
by Julian Seward.
\n
"
" Copyright (C) 1996-201
9
by Julian Seward.
\n
"
"
\n
"
"
\n
"
" This program is free software; you can redistribute it and/or modify
\n
"
" This program is free software; you can redistribute it and/or modify
\n
"
" it under the terms set out in the LICENSE file, which is included
\n
"
" it under the terms set out in the LICENSE file, which is included
\n
"
...
...
bzip2recover.c
View file @
fb69e223
...
@@ -7,8 +7,8 @@
...
@@ -7,8 +7,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -314,7 +314,7 @@ Int32 main ( Int32 argc, Char** argv )
...
@@ -314,7 +314,7 @@ Int32 main ( Int32 argc, Char** argv )
inFileName
[
0
]
=
outFileName
[
0
]
=
0
;
inFileName
[
0
]
=
outFileName
[
0
]
=
0
;
fprintf
(
stderr
,
fprintf
(
stderr
,
"bzip2recover 1.0.
7
: extracts blocks from damaged .bz2 files.
\n
"
);
"bzip2recover 1.0.
8
: extracts blocks from damaged .bz2 files.
\n
"
);
if
(
argc
!=
2
)
{
if
(
argc
!=
2
)
{
fprintf
(
stderr
,
"%s: usage is `%s damaged_file_name'.
\n
"
,
fprintf
(
stderr
,
"%s: usage is `%s damaged_file_name'.
\n
"
,
...
...
bzlib.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -43,12 +43,12 @@ void BZ2_bz__AssertH__fail ( int errcode )
...
@@ -43,12 +43,12 @@ void BZ2_bz__AssertH__fail ( int errcode )
fprintf
(
stderr
,
fprintf
(
stderr
,
"
\n\n
bzip2/libbzip2: internal error number %d.
\n
"
"
\n\n
bzip2/libbzip2: internal error number %d.
\n
"
"This is a bug in bzip2/libbzip2, %s.
\n
"
"This is a bug in bzip2/libbzip2, %s.
\n
"
"Please report it to
me at: jseward@acm
.org. If this happened
\n
"
"Please report it to
: bzip2-devel@sourceware
.org. If this happened
\n
"
"when you were using some program which uses libbzip2 as a
\n
"
"when you were using some program which uses libbzip2 as a
\n
"
"component, you should also report this bug to the author(s)
\n
"
"component, you should also report this bug to the author(s)
\n
"
"of that program. Please make an effort to report this bug;
\n
"
"of that program. Please make an effort to report this bug;
\n
"
"timely and accurate bug reports eventually lead to higher
\n
"
"timely and accurate bug reports eventually lead to higher
\n
"
"quality software. Thanks.
Julian Seward, 10 December 2007.
\n\n
"
,
"quality software. Thanks.
\n\n
"
,
errcode
,
errcode
,
BZ2_bzlibVersion
()
BZ2_bzlibVersion
()
);
);
...
...
bzlib.h
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
bzlib_private.h
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -36,7 +36,7 @@
...
@@ -36,7 +36,7 @@
/*-- General stuff. --*/
/*-- General stuff. --*/
#define BZ_VERSION "1.0.
7
,
27
-Ju
n
-2019"
#define BZ_VERSION "1.0.
8
,
13
-Ju
l
-2019"
typedef
char
Char
;
typedef
char
Char
;
typedef
unsigned
char
Bool
;
typedef
unsigned
char
Bool
;
...
...
compress.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -454,7 +454,7 @@ void sendMTFValues ( EState* s )
...
@@ -454,7 +454,7 @@ void sendMTFValues ( EState* s )
AssertH
(
nGroups
<
8
,
3002
);
AssertH
(
nGroups
<
8
,
3002
);
AssertH
(
nSelectors
<
32768
&&
AssertH
(
nSelectors
<
32768
&&
nSelectors
<=
(
2
+
(
900000
/
BZ_G_SIZE
))
,
nSelectors
<=
BZ_MAX_SELECTORS
,
3003
);
3003
);
...
...
crctable.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
decompress.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
@@ -287,7 +287,7 @@ Int32 BZ2_decompress ( DState* s )
...
@@ -287,7 +287,7 @@ Int32 BZ2_decompress ( DState* s )
GET_BITS
(
BZ_X_SELECTOR_1
,
nGroups
,
3
);
GET_BITS
(
BZ_X_SELECTOR_1
,
nGroups
,
3
);
if
(
nGroups
<
2
||
nGroups
>
BZ_N_GROUPS
)
RETURN
(
BZ_DATA_ERROR
);
if
(
nGroups
<
2
||
nGroups
>
BZ_N_GROUPS
)
RETURN
(
BZ_DATA_ERROR
);
GET_BITS
(
BZ_X_SELECTOR_2
,
nSelectors
,
15
);
GET_BITS
(
BZ_X_SELECTOR_2
,
nSelectors
,
15
);
if
(
nSelectors
<
1
||
nSelectors
>
BZ_MAX_SELECTORS
)
RETURN
(
BZ_DATA_ERROR
);
if
(
nSelectors
<
1
)
RETURN
(
BZ_DATA_ERROR
);
for
(
i
=
0
;
i
<
nSelectors
;
i
++
)
{
for
(
i
=
0
;
i
<
nSelectors
;
i
++
)
{
j
=
0
;
j
=
0
;
while
(
True
)
{
while
(
True
)
{
...
@@ -296,8 +296,14 @@ Int32 BZ2_decompress ( DState* s )
...
@@ -296,8 +296,14 @@ Int32 BZ2_decompress ( DState* s )
j
++
;
j
++
;
if
(
j
>=
nGroups
)
RETURN
(
BZ_DATA_ERROR
);
if
(
j
>=
nGroups
)
RETURN
(
BZ_DATA_ERROR
);
}
}
s
->
selectorMtf
[
i
]
=
j
;
/* Having more than BZ_MAX_SELECTORS doesn't make much sense
since they will never be used, but some implementations might
"round up" the number of selectors, so just ignore those. */
if
(
i
<
BZ_MAX_SELECTORS
)
s
->
selectorMtf
[
i
]
=
j
;
}
}
if
(
nSelectors
>
BZ_MAX_SELECTORS
)
nSelectors
=
BZ_MAX_SELECTORS
;
/*--- Undo the MTF values for the selectors. ---*/
/*--- Undo the MTF values for the selectors. ---*/
{
{
...
...
huffman.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
randtable.c
View file @
fb69e223
...
@@ -8,8 +8,8 @@
...
@@ -8,8 +8,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
spewG.c
View file @
fb69e223
...
@@ -13,8 +13,8 @@
...
@@ -13,8 +13,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
unzcrash.c
View file @
fb69e223
...
@@ -17,8 +17,8 @@
...
@@ -17,8 +17,8 @@
This file is part of bzip2/libbzip2, a program and library for
This file is part of bzip2/libbzip2, a program and library for
lossless, block-sorting data compression.
lossless, block-sorting data compression.
bzip2/libbzip2 version 1.0.
7
of
27
Ju
ne
2019
bzip2/libbzip2 version 1.0.
8
of
13
Ju
ly
2019
Copyright (C) 1996-201
0
Julian Seward <jseward@acm.org>
Copyright (C) 1996-201
9
Julian Seward <jseward@acm.org>
Please read the WARNING, DISCLAIMER and PATENTS sections in the
Please read the WARNING, DISCLAIMER and PATENTS sections in the
README file.
README file.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment