From 64ab85d0ebe2704b8774daa909244889e8ea15a6 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 14:45:03 +0100 Subject: [PATCH 01/10] Adding upstream version 0.6. Signed-off-by: Daniel Baumann --- ChangeLog | 7 +- INSTALL | 18 +- Makefile.in | 16 +- NEWS | 2 +- README | 26 +- configure | 8 +- lzd.cc | 31 +- testsuite/check.sh | 8 +- testsuite/test.txt | 1212 ++++++++++++++++++++--------------------- testsuite/test.txt.lz | Bin 11518 -> 7376 bytes 10 files changed, 678 insertions(+), 650 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8921458..f1ad554 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2014-08-25 Antonio Diaz Diaz + + * Version 0.6 released. + * Minor changes. + 2013-09-17 Antonio Diaz Diaz * Version 0.5 released. @@ -23,7 +28,7 @@ * Version 0.1 released. -Copyright (C) 2013 Antonio Diaz Diaz. +Copyright (C) 2013, 2014 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute and diff --git a/INSTALL b/INSTALL index 61635f7..d9a0ccb 100644 --- a/INSTALL +++ b/INSTALL @@ -1,7 +1,7 @@ Requirements ------------ You will need a C++ compiler. -I use gcc 4.8.1 and 3.3.6, but the code should compile with any +I use gcc 4.9.1 and 3.3.6, but the code should compile with any standards compliant compiler. Gcc is available at http://gcc.gnu.org. @@ -32,19 +32,19 @@ the main archive. 5. Type 'make install' to install the program and any data files and documentation. - You can install only the program, the info manual or the man page + You can install only the program, the info manual or the man page by typing 'make install-bin', 'make install-info' or 'make install-man' respectively. Another way ----------- -You can also compile lzd into a separate directory. To do this, you -must use a version of 'make' that supports the 'VPATH' variable, such -as GNU 'make'. 'cd' to the directory where you want the object files -and executables to go and run the 'configure' script. 'configure' -automatically checks for the source code in '.', in '..' and in the -directory that 'configure' is in. +You can also compile lzd into a separate directory. +To do this, you must use a version of 'make' that supports the 'VPATH' +variable, such as GNU 'make'. 'cd' to the directory where you want the +object files and executables to go and run the 'configure' script. +'configure' automatically checks for the source code in '.', in '..' and +in the directory that 'configure' is in. 'configure' recognizes the option '--srcdir=DIR' to control where to look for the sources. Usually 'configure' can determine that directory @@ -54,7 +54,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013 Antonio Diaz Diaz. +Copyright (C) 2013, 2014 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/Makefile.in b/Makefile.in index 9a4b5ec..fa4ce0f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,8 +1,8 @@ DISTNAME = $(pkgname)-$(pkgversion) INSTALL = install -INSTALL_PROGRAM = $(INSTALL) -p -m 755 -INSTALL_DATA = $(INSTALL) -p -m 644 +INSTALL_PROGRAM = $(INSTALL) -m 755 +INSTALL_DATA = $(INSTALL) -m 644 INSTALL_DIR = $(INSTALL) -d -m 755 SHELL = /bin/sh @@ -16,13 +16,13 @@ objs = lzd.o all : $(progname) $(progname) : $(objs) - $(CXX) $(LDFLAGS) -o $@ $(objs) + $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ $(objs) $(progname)_profiled : $(objs) - $(CXX) $(LDFLAGS) -pg -o $@ $(objs) + $(CXX) $(CXXFLAGS) $(LDFLAGS) -pg -o $@ $(objs) %.o : %.cc - $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $< + $(CXX) $(CXXFLAGS) $(CPPFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $< $(objs) : Makefile @@ -31,8 +31,8 @@ doc : info : $(VPATH)/doc/$(pkgname).info -$(VPATH)/doc/$(pkgname).info : $(VPATH)/doc/$(pkgname).texinfo - cd $(VPATH)/doc && makeinfo $(pkgname).texinfo +$(VPATH)/doc/$(pkgname).info : $(VPATH)/doc/$(pkgname).texi + cd $(VPATH)/doc && makeinfo $(pkgname).texi man : $(VPATH)/doc/$(progname).1 @@ -78,7 +78,7 @@ uninstall-man : dist : doc ln -sf $(VPATH) $(DISTNAME) - tar -cvf $(DISTNAME).tar \ + tar -Hustar --owner=root --group=root -cvf $(DISTNAME).tar \ $(DISTNAME)/AUTHORS \ $(DISTNAME)/ChangeLog \ $(DISTNAME)/INSTALL \ diff --git a/NEWS b/NEWS index 9be0ea7..53c0fc7 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,3 @@ -Changes in version 0.5: +Changes in version 0.6: Minor changes. diff --git a/README b/README index fcfe639..400ef93 100644 --- a/README +++ b/README @@ -13,6 +13,30 @@ correctly decompress the concatenation of two or more compressed files. The result is the concatenation of the corresponding decompressed data. Integrity of such concatenated compressed input is also verified. +The lzip file format is designed for long-term data archiving, taking +into account both data integrity and decoder availability: + + * The lzip format provides very safe integrity checking and some data + recovery means. The lziprecover program can repair bit-flip errors + (one of the most common forms of data corruption) in lzip files, + and provides data recovery capabilities, including error-checked + merging of damaged copies of a file. + + * The lzip format is as simple as possible (but not simpler). The + lzip manual provides the code of a simple decompressor along with a + detailed explanation of how it works, so that with the only help of + the lzip manual it would be possible for a digital archaeologist to + extract the data from a lzip file long after quantum computers + eventually render LZMA obsolete. + + * Additionally lzip is copylefted, which guarantees that it will + remain free forever. + +A nice feature of the lzip format is that a corrupt byte is easier to +repair the nearer it is from the beginning of the file. Therefore, with +the help of lziprecover, losing an entire archive just because of a +corrupt byte near the beginning is a thing of the past. + The ideas embodied in lzd are due to (at least) the following people: Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for the definition of Markov chains), G.N.N. Martin (for the definition of @@ -20,7 +44,7 @@ range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013 Antonio Diaz Diaz. +Copyright (C) 2013, 2014 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/configure b/configure index 3f7c890..d380090 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013 Antonio Diaz Diaz. +# Copyright (C) 2013, 2014 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute and modify it. pkgname=lzd -pkgversion=0.5 +pkgversion=0.6 progname=lzd srctrigger=lzd.cc @@ -64,7 +64,7 @@ while [ $# != 0 ] ; do echo " --datarootdir=DIR base directory for doc and data [${datarootdir}]" echo " --infodir=DIR info files directory [${infodir}]" echo " --mandir=DIR man pages directory [${mandir}]" - echo " CXX=COMPILER C++ compiler to use [g++]" + echo " CXX=COMPILER C++ compiler to use [${CXX}]" echo " CPPFLAGS=OPTIONS command line options for the preprocessor [${CPPFLAGS}]" echo " CXXFLAGS=OPTIONS command line options for the C++ compiler [${CXXFLAGS}]" echo " LDFLAGS=OPTIONS command line options for the linker [${LDFLAGS}]" @@ -165,7 +165,7 @@ echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013 Antonio Diaz Diaz. +# Copyright (C) 2013, 2014 Antonio Diaz Diaz. # This file was generated automatically by configure. Do not edit. # # This Makefile is free software: you have unlimited permission diff --git a/lzd.cc b/lzd.cc index b069f0c..f1a500e 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for lzip files - Copyright (C) 2013 Antonio Diaz Diaz. + Copyright (C) 2013, 2014 Antonio Diaz Diaz. This program is free software: you have unlimited permission to copy, distribute and modify it. @@ -21,7 +21,7 @@ #include #include #include -#if defined(__MSVCRT__) || defined(__OS2__) +#if defined(__MSVCRT__) || defined(__OS2__) || defined(_MSC_VER) #include #include #endif @@ -213,7 +213,7 @@ public: break; } } - return symbol - 0x100; + return symbol & 0xFF; } int decode_len( Len_model & lm, const int pos_state ) @@ -263,7 +263,7 @@ public: pos( 0 ), stream_pos( 0 ), crc_( 0xFFFFFFFFU ) - { buffer[dictionary_size-1] = 0; } // prev_byte of first_byte + { buffer[dictionary_size-1] = 0; } // prev_byte of first byte ~LZ_decoder() { delete[] buffer; } @@ -282,7 +282,7 @@ void LZ_decoder::flush_data() crc32.update_buf( crc_, buffer + stream_pos, size ); errno = 0; if( std::fwrite( buffer + stream_pos, 1, size, stdout ) != size ) - { std::fprintf( stderr, "Write error: %s\n", std::strerror( errno ) ); + { std::fprintf( stderr, "Write error: %s.\n", std::strerror( errno ) ); std::exit( 1 ); } if( pos >= dictionary_size ) { partial_data_pos += pos; pos = 0; } stream_pos = pos; @@ -380,13 +380,13 @@ bool LZ_decoder::decode_member() // Returns false if error } } state.set_match(); - if( rep0 >= dictionary_size || ( rep0 >= pos && !partial_data_pos ) ) - return false; + if( rep0 >= dictionary_size || rep0 >= data_position() ) + { flush_data(); return false; } } - for( int i = 0; i < len; ++i ) - put_byte( get_byte( rep0 ) ); + for( int i = 0; i < len; ++i ) put_byte( get_byte( rep0 ) ); } } + flush_data(); return false; } @@ -402,7 +402,7 @@ int main( const int argc, const char * const argv[] ) "It is not safe to use lzd for any real work.\n" "\nUsage: %s < file.lz > file\n", argv[0] ); std::printf( "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2013 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2014 Antonio Diaz Diaz.\n" "This is free software: you are free to change and redistribute it.\n" "There is NO WARRANTY, to the extent permitted by law.\n" "Report bugs to lzip-bug@nongnu.org\n" @@ -410,16 +410,15 @@ int main( const int argc, const char * const argv[] ) return 0; } -#if defined(__MSVCRT__) || defined(__OS2__) - setmode( STDIN_FILENO, O_BINARY ); - setmode( STDOUT_FILENO, O_BINARY ); +#if defined(__MSVCRT__) || defined(__OS2__) || defined(_MSC_VER) + setmode( fileno( stdin ), O_BINARY ); + setmode( fileno( stdout ), O_BINARY ); #endif for( bool first_member = true; ; first_member = false ) { File_header header; - for( int i = 0; i < 6; ++i ) - header[i] = std::getc( stdin ); + for( int i = 0; i < 6; ++i ) header[i] = std::getc( stdin ); if( std::feof( stdin ) || std::memcmp( header, "LZIP", 4 ) != 0 ) { if( first_member ) @@ -454,7 +453,7 @@ int main( const int argc, const char * const argv[] ) } if( std::fclose( stdout ) != 0 ) - { std::fprintf( stderr, "Can't close stdout: %s\n", std::strerror( errno ) ); + { std::fprintf( stderr, "Can't close stdout: %s.\n", std::strerror( errno ) ); return 1; } return 0; } diff --git a/testsuite/check.sh b/testsuite/check.sh index 5eaa679..0cdc668 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013 Antonio Diaz Diaz. +# Copyright (C) 2013, 2014 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute and modify it. @@ -12,7 +12,7 @@ testdir=`cd "$1" ; pwd` LZIP="${objdir}"/lzd framework_failure() { echo "failure in testing framework" ; exit 1 ; } -if [ ! -x "${LZIP}" ] ; then +if [ ! -f "${LZIP}" ] || [ ! -x "${LZIP}" ] ; then echo "${LZIP}: cannot execute" exit 1 fi @@ -28,10 +28,10 @@ fail=0 printf "testing lzd-%s..." "$2" "${LZIP}" < "${in}" 2> /dev/null -if [ $? = 2 ] ; then printf . ; else fail=1 ; printf - ; fi +if [ $? = 2 ] ; then printf . ; else printf - ; fail=1 ; fi dd if="${in_lz}" bs=1 count=6 2> /dev/null | "${LZIP}" 2> /dev/null if [ $? = 2 ] ; then printf . ; else printf - ; fail=1 ; fi -dd if="${in_lz}" bs=1 count=20 2> /dev/null | "${LZIP}" 2> /dev/null +dd if="${in_lz}" bs=1 count=20 2> /dev/null | "${LZIP}" > /dev/null 2>&1 if [ $? = 2 ] ; then printf . ; else printf - ; fail=1 ; fi "${LZIP}" < "${in_lz}" > copy || fail=1 diff --git a/testsuite/test.txt b/testsuite/test.txt index 5b244d5..9196a3a 100644 --- a/testsuite/test.txt +++ b/testsuite/test.txt @@ -1,627 +1,623 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. - Preamble + Preamble - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to this License. - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. - 13. Use with the GNU Affero General Public License. +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. - 14. Revised Versions of this License. +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. + NO WARRANTY - 15. Disclaimer of Warranty. + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. - 16. Limitation of Liability. + END OF TERMS AND CONDITIONS - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs + How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it @@ -629,7 +625,7 @@ free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least +convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. @@ -637,7 +633,7 @@ the "copyright" line and a pointer to where the full notice is found. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or + the Free Software Foundation, either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, @@ -650,27 +646,31 @@ the "copyright" line and a pointer to where the full notice is found. Also add information on how to contact you by electronic and paper mail. - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + Gnomovision version 69, Copyright (C) + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. diff --git a/testsuite/test.txt.lz b/testsuite/test.txt.lz index 4db881aa68489345e86b677d05091a773f26bbb5..41d2e39999a92cd871d646a4ae00ba25ef067cc4 100644 GIT binary patch literal 7376 zcmV;>953TcT1ij=@Bk2P{zoSj_#!9yd85m~Qwmg_>XQzzlf~T8KnF+*R^l+=IY)he zA3cznl2!%qBGY}jyMe(7E(*-#rlxR7NzGHMzr|2s3(He9`GTAPy5F|T7T`=4Uf1Uw zR`xa?@bsAm;#8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rFBxk5b$D1ooo@m)?zeVE=0r?Ga(7y6Kp*6pa+&Q zvRmsf{n?w8y2#hY4(J1wS=LtxT2vH%%{&&t08Y|V@?ni9y5EWP`U1{sTW{v!kY+4^ z+S0I~6>cbn2tEu?KVK1_&YzrD@MaApY%_CU!3pkjplZK1B-d@3N^{BDkvcR8I9Wv~ zuX}M|B15Z7?`?#qx`-TTqt^z@FH;sg*I<$$Fo4J5M+hh1tSn+&$4})umtf@As(NdX=wsZ-4;usHa)5QB$1aIh?9cGlcK>b|@g`!p270bc@37inU1(&^ z$opB&)Ll*(H<*4b$Hb|OR%j0rl=(ZfTfTK-AKoaiS`tg`pq9SG{JEiqEW8H}eo>_lPASr^+$(mLzqvm92i4^F&O zKC2v#(YdT=)sBQcG4LKc1so^hf0*9~xO&F|0#4$u{JR8SVPC9vEiLE>CZn+KO%mN9%x8~EWo{(jMACLMIU;msDVyGilST(q^< kW3(FWURRxZ|KJ+}cYNd{wV;at000000RAih0000005ZcT;Q#;t From 2c6d5ecc7e0adff55b38bb04e71ec5f668ade67f Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 14:49:45 +0100 Subject: [PATCH 02/10] Adding upstream version 0.7. Signed-off-by: Daniel Baumann --- ChangeLog | 7 ++++++- INSTALL | 8 ++------ Makefile.in | 36 +++++++++++++++++++++++------------- NEWS | 2 +- README | 13 +++++++------ configure | 10 +++++----- lzd.cc | 46 ++++++++++++++++++++-------------------------- testsuite/check.sh | 2 +- 8 files changed, 65 insertions(+), 59 deletions(-) diff --git a/ChangeLog b/ChangeLog index f1ad554..1200ef9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2015-07-07 Antonio Diaz Diaz + + * Version 0.7 released. + * Minor changes. + 2014-08-25 Antonio Diaz Diaz * Version 0.6 released. @@ -28,7 +33,7 @@ * Version 0.1 released. -Copyright (C) 2013, 2014 Antonio Diaz Diaz. +Copyright (C) 2013-2015 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute and diff --git a/INSTALL b/INSTALL index d9a0ccb..7260e4a 100644 --- a/INSTALL +++ b/INSTALL @@ -1,7 +1,7 @@ Requirements ------------ You will need a C++ compiler. -I use gcc 4.9.1 and 3.3.6, but the code should compile with any +I use gcc 4.9.1 and 4.1.2, but the code should compile with any standards compliant compiler. Gcc is available at http://gcc.gnu.org. @@ -32,10 +32,6 @@ the main archive. 5. Type 'make install' to install the program and any data files and documentation. - You can install only the program, the info manual or the man page by - typing 'make install-bin', 'make install-info' or 'make install-man' - respectively. - Another way ----------- @@ -54,7 +50,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013, 2014 Antonio Diaz Diaz. +Copyright (C) 2013-2015 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/Makefile.in b/Makefile.in index fa4ce0f..b125b52 100644 --- a/Makefile.in +++ b/Makefile.in @@ -9,20 +9,19 @@ SHELL = /bin/sh objs = lzd.o -.PHONY : all install install-bin install-info install-man install-strip \ +.PHONY : all install install-bin install-info install-man \ + install-strip install-compress install-strip-compress \ + install-bin-strip install-info-compress install-man-compress \ uninstall uninstall-bin uninstall-info uninstall-man \ doc info man check dist clean distclean all : $(progname) $(progname) : $(objs) - $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ $(objs) - -$(progname)_profiled : $(objs) - $(CXX) $(CXXFLAGS) $(LDFLAGS) -pg -o $@ $(objs) + $(CXX) $(LDFLAGS) $(CXXFLAGS) -o $@ $(objs) %.o : %.cc - $(CXX) $(CXXFLAGS) $(CPPFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $< + $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $< $(objs) : Makefile @@ -37,7 +36,7 @@ $(VPATH)/doc/$(pkgname).info : $(VPATH)/doc/$(pkgname).texi man : $(VPATH)/doc/$(progname).1 $(VPATH)/doc/$(progname).1 : $(progname) - help2man -n 'educational decompressor for lzip files' \ + help2man -n 'educational decompressor for the lzip format' \ -o $@ --no-info ./$(progname) Makefile : $(VPATH)/configure $(VPATH)/Makefile.in @@ -47,34 +46,45 @@ check : all @$(VPATH)/testsuite/check.sh $(VPATH)/testsuite $(pkgversion) install : install-bin +install-strip : install-bin-strip +install-compress : install-bin +install-strip-compress : install-bin-strip install-bin : all if [ ! -d "$(DESTDIR)$(bindir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(bindir)" ; fi $(INSTALL_PROGRAM) ./$(progname) "$(DESTDIR)$(bindir)/$(progname)" +install-bin-strip : all + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install-bin + install-info : if [ ! -d "$(DESTDIR)$(infodir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(infodir)" ; fi + -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info"* $(INSTALL_DATA) $(VPATH)/doc/$(pkgname).info "$(DESTDIR)$(infodir)/$(pkgname).info" -install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$(pkgname).info" +install-info-compress : install-info + lzip -v -9 "$(DESTDIR)$(infodir)/$(pkgname).info" + install-man : if [ ! -d "$(DESTDIR)$(mandir)/man1" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(mandir)/man1" ; fi + -rm -f "$(DESTDIR)$(mandir)/man1/$(progname).1"* $(INSTALL_DATA) $(VPATH)/doc/$(progname).1 "$(DESTDIR)$(mandir)/man1/$(progname).1" -install-strip : all - $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install +install-man-compress : install-man + lzip -v -9 "$(DESTDIR)$(mandir)/man1/$(progname).1" -uninstall : uninstall-bin uninstall-info uninstall-man +uninstall : uninstall-bin uninstall-bin : -rm -f "$(DESTDIR)$(bindir)/$(progname)" uninstall-info : -install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$(pkgname).info" - -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info" + -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info"* uninstall-man : - -rm -f "$(DESTDIR)$(mandir)/man1/$(progname).1" + -rm -f "$(DESTDIR)$(mandir)/man1/$(progname).1"* dist : doc ln -sf $(VPATH) $(DISTNAME) @@ -94,7 +104,7 @@ dist : doc lzip -v -9 $(DISTNAME).tar clean : - -rm -f $(progname) $(progname)_profiled $(objs) + -rm -f $(progname) $(objs) distclean : clean -rm -f Makefile config.status *.tar *.tar.lz diff --git a/NEWS b/NEWS index 53c0fc7..e58eb7f 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,3 @@ -Changes in version 0.6: +Changes in version 0.7: Minor changes. diff --git a/README b/README index 400ef93..55c1c52 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ Description -Lzd is a simplified decompressor for lzip files with an educational +Lzd is a simplified decompressor for the lzip format with an educational purpose. Studying its source is a good first step to understand how lzip works. It is not safe to use lzd for any real work. @@ -13,8 +13,9 @@ correctly decompress the concatenation of two or more compressed files. The result is the concatenation of the corresponding decompressed data. Integrity of such concatenated compressed input is also verified. -The lzip file format is designed for long-term data archiving, taking -into account both data integrity and decoder availability: +The lzip file format is designed for data sharing and long-term +archiving, taking into account both data integrity and decoder +availability: * The lzip format provides very safe integrity checking and some data recovery means. The lziprecover program can repair bit-flip errors @@ -29,8 +30,8 @@ into account both data integrity and decoder availability: extract the data from a lzip file long after quantum computers eventually render LZMA obsolete. - * Additionally lzip is copylefted, which guarantees that it will - remain free forever. + * Additionally the lzip reference implementation is copylefted, which + guarantees that it will remain free forever. A nice feature of the lzip format is that a corrupt byte is easier to repair the nearer it is from the beginning of the file. Therefore, with @@ -44,7 +45,7 @@ range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013, 2014 Antonio Diaz Diaz. +Copyright (C) 2013-2015 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/configure b/configure index d380090..70ed8c3 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh -# configure script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013, 2014 Antonio Diaz Diaz. +# configure script for Lzd - Educational decompressor for the lzip format +# Copyright (C) 2013-2015 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute and modify it. pkgname=lzd -pkgversion=0.6 +pkgversion=0.7 progname=lzd srctrigger=lzd.cc @@ -164,8 +164,8 @@ echo "CXXFLAGS = ${CXXFLAGS}" echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF -# Makefile for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013, 2014 Antonio Diaz Diaz. +# Makefile for Lzd - Educational decompressor for the lzip format +# Copyright (C) 2013-2015 Antonio Diaz Diaz. # This file was generated automatically by configure. Do not edit. # # This Makefile is free software: you have unlimited permission diff --git a/lzd.cc b/lzd.cc index f1a500e..30dde48 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ -/* Lzd - Educational decompressor for lzip files - Copyright (C) 2013, 2014 Antonio Diaz Diaz. +/* Lzd - Educational decompressor for the lzip format + Copyright (C) 2013-2015 Antonio Diaz Diaz. This program is free software: you have unlimited permission to copy, distribute and modify it. @@ -241,7 +241,7 @@ class LZ_decoder void flush_data(); - uint8_t get_byte( const unsigned distance ) const + uint8_t peek( const unsigned distance ) const { unsigned i = pos - distance - 1; if( pos <= distance ) i += dictionary_size; @@ -255,7 +255,7 @@ class LZ_decoder } public: - LZ_decoder( const unsigned dict_size ) + explicit LZ_decoder( const unsigned dict_size ) : partial_data_pos( 0 ), dictionary_size( dict_size ), @@ -282,7 +282,7 @@ void LZ_decoder::flush_data() crc32.update_buf( crc_, buffer + stream_pos, size ); errno = 0; if( std::fwrite( buffer + stream_pos, 1, size, stdout ) != size ) - { std::fprintf( stderr, "Write error: %s.\n", std::strerror( errno ) ); + { std::fprintf( stderr, "Write error: %s\n", std::strerror( errno ) ); std::exit( 1 ); } if( pos >= dictionary_size ) { partial_data_pos += pos; pos = 0; } stream_pos = pos; @@ -315,16 +315,16 @@ bool LZ_decoder::decode_member() // Returns false if error const int pos_state = data_position() & pos_state_mask; if( rdec.decode_bit( bm_match[state()][pos_state] ) == 0 ) // 1st bit { - const uint8_t prev_byte = get_byte( 0 ); + const uint8_t prev_byte = peek( 0 ); const int literal_state = prev_byte >> ( 8 - literal_context_bits ); Bit_model * const bm = bm_literal[literal_state]; if( state.is_char() ) put_byte( rdec.decode_tree( bm, 8 ) ); else - put_byte( rdec.decode_matched( bm, get_byte( rep0 ) ) ); + put_byte( rdec.decode_matched( bm, peek( rep0 ) ) ); state.set_char(); } - else + else // match or repeated match { int len; if( rdec.decode_bit( bm_rep[state()] ) != 0 ) // 2nd bit @@ -348,12 +348,12 @@ bool LZ_decoder::decode_member() // Returns false if error else { if( rdec.decode_bit( bm_len[state()][pos_state] ) == 0 ) // 4th bit - { state.set_short_rep(); put_byte( get_byte( rep0 ) ); continue; } + { state.set_short_rep(); put_byte( peek( rep0 ) ); continue; } } state.set_rep(); len = min_match_len + rdec.decode_len( rep_len_model, pos_state ); } - else + else // match { rep3 = rep2; rep2 = rep1; rep1 = rep0; len = min_match_len + rdec.decode_len( match_len_model, pos_state ); @@ -372,7 +372,7 @@ bool LZ_decoder::decode_member() // Returns false if error { rep0 += rdec.decode( direct_bits - dis_align_bits ) << dis_align_bits; rep0 += rdec.decode_tree_reversed( bm_align, dis_align_bits ); - if( rep0 == 0xFFFFFFFFU ) // Marker found + if( rep0 == 0xFFFFFFFFU ) // marker found { flush_data(); return ( len == min_match_len ); // End Of Stream marker @@ -383,7 +383,7 @@ bool LZ_decoder::decode_member() // Returns false if error if( rep0 >= dictionary_size || rep0 >= data_position() ) { flush_data(); return false; } } - for( int i = 0; i < len; ++i ) put_byte( get_byte( rep0 ) ); + for( int i = 0; i < len; ++i ) put_byte( peek( rep0 ) ); } } flush_data(); @@ -395,14 +395,14 @@ int main( const int argc, const char * const argv[] ) { if( argc > 1 ) { - std::printf( "Lzd %s - Educational decompressor for lzip files.\n", + std::printf( "Lzd %s - Educational decompressor for the lzip format.\n", PROGVERSION ); std::printf( "Study the source to learn how a lzip decompressor works.\n" "See the lzip manual for an explanation of the code.\n" "It is not safe to use lzd for any real work.\n" "\nUsage: %s < file.lz > file\n", argv[0] ); std::printf( "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2014 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2015 Antonio Diaz Diaz.\n" "This is free software: you are free to change and redistribute it.\n" "There is NO WARRANTY, to the extent permitted by law.\n" "Report bugs to lzip-bug@nongnu.org\n" @@ -419,28 +419,22 @@ int main( const int argc, const char * const argv[] ) { File_header header; for( int i = 0; i < 6; ++i ) header[i] = std::getc( stdin ); - if( std::feof( stdin ) || std::memcmp( header, "LZIP", 4 ) != 0 ) + if( std::feof( stdin ) || std::memcmp( header, "LZIP\x01", 5 ) != 0 ) { if( first_member ) - { std::fprintf( stderr, "Bad magic number (file not in lzip format)\n" ); + { std::fputs( "Bad magic number (file not in lzip format).\n", stderr ); return 2; } break; } - if( header[4] != 1 ) - { - std::fprintf( stderr, "Version %d member format not supported.\n", - header[4] ); - return 2; - } unsigned dict_size = 1 << ( header[5] & 0x1F ); dict_size -= ( dict_size / 16 ) * ( ( header[5] >> 5 ) & 7 ); if( dict_size < min_dictionary_size || dict_size > max_dictionary_size ) - { std::fprintf( stderr, "Invalid dictionary size in member header\n" ); + { std::fputs( "Invalid dictionary size in member header.\n", stderr ); return 2; } LZ_decoder decoder( dict_size ); if( !decoder.decode_member() ) - { std::fprintf( stderr, "Data error\n" ); return 2; } + { std::fputs( "Data error\n", stderr ); return 2; } File_trailer trailer; for( int i = 0; i < 20; ++i ) trailer[i] = std::getc( stdin ); @@ -449,11 +443,11 @@ int main( const int argc, const char * const argv[] ) unsigned long long data_size = 0; for( int i = 11; i >= 4; --i ) { data_size <<= 8; data_size += trailer[i]; } if( crc != decoder.crc() || data_size != decoder.data_position() ) - { std::fprintf( stderr, "CRC error\n" ); return 2; } + { std::fputs( "CRC error\n", stderr ); return 2; } } if( std::fclose( stdout ) != 0 ) - { std::fprintf( stderr, "Can't close stdout: %s.\n", std::strerror( errno ) ); + { std::fprintf( stderr, "Can't close stdout: %s\n", std::strerror( errno ) ); return 1; } return 0; } diff --git a/testsuite/check.sh b/testsuite/check.sh index 0cdc668..cf0a940 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013, 2014 Antonio Diaz Diaz. +# Copyright (C) 2013-2015 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute and modify it. From 4502486013dc2fe3a95dc4b633163476f3cf7fba Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 14:58:19 +0100 Subject: [PATCH 03/10] Adding upstream version 0.8. Signed-off-by: Daniel Baumann --- ChangeLog | 7 ++++++- INSTALL | 2 +- NEWS | 5 +++-- README | 2 +- configure | 10 +++++----- lzd.cc | 14 +++++++++----- testsuite/check.sh | 2 +- 7 files changed, 26 insertions(+), 16 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1200ef9..3aaf64a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2016-01-23 Antonio Diaz Diaz + + * Version 0.8 released. + * Documented that lzip does not use 'literal_pos_state_bits'. + 2015-07-07 Antonio Diaz Diaz * Version 0.7 released. @@ -33,7 +38,7 @@ * Version 0.1 released. -Copyright (C) 2013-2015 Antonio Diaz Diaz. +Copyright (C) 2013-2016 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute and diff --git a/INSTALL b/INSTALL index 7260e4a..014ab3f 100644 --- a/INSTALL +++ b/INSTALL @@ -50,7 +50,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2015 Antonio Diaz Diaz. +Copyright (C) 2013-2016 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/NEWS b/NEWS index e58eb7f..57ca1b3 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,4 @@ -Changes in version 0.7: +Changes in version 0.8: -Minor changes. +It has been documented that lzip does not use the LZMA parameter +'literal_pos_state_bits'. diff --git a/README b/README index 55c1c52..ae73fc1 100644 --- a/README +++ b/README @@ -45,7 +45,7 @@ range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2015 Antonio Diaz Diaz. +Copyright (C) 2013-2016 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/configure b/configure index 70ed8c3..83d3447 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2015 Antonio Diaz Diaz. +# Copyright (C) 2013-2016 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute and modify it. pkgname=lzd -pkgversion=0.7 +pkgversion=0.8 progname=lzd srctrigger=lzd.cc @@ -139,7 +139,7 @@ if [ -z "${no_create}" ] ; then rm -f config.status cat > config.status << EOF #! /bin/sh -# This file was generated automatically by configure. Do not edit. +# This file was generated automatically by configure. Don't edit. # Run this file to recreate the current configuration. # # This script is free software: you have unlimited permission @@ -165,8 +165,8 @@ echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2015 Antonio Diaz Diaz. -# This file was generated automatically by configure. Do not edit. +# Copyright (C) 2013-2016 Antonio Diaz Diaz. +# This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission # to copy, distribute and modify it. diff --git a/lzd.cc b/lzd.cc index 30dde48..5f8dcdc 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2015 Antonio Diaz Diaz. + Copyright (C) 2013-2016 Antonio Diaz Diaz. This program is free software: you have unlimited permission to copy, distribute and modify it. @@ -52,6 +52,7 @@ enum { min_dictionary_size = 1 << 12, max_dictionary_size = 1 << 29, literal_context_bits = 3, + literal_pos_state_bits = 0, // not used pos_state_bits = 2, pos_states = 1 << pos_state_bits, pos_state_mask = pos_states - 1, @@ -238,6 +239,7 @@ class LZ_decoder unsigned pos; // current pos in buffer unsigned stream_pos; // first byte not yet written to stdout uint32_t crc_; + bool pos_wrapped; void flush_data(); @@ -262,7 +264,8 @@ public: buffer( new uint8_t[dictionary_size] ), pos( 0 ), stream_pos( 0 ), - crc_( 0xFFFFFFFFU ) + crc_( 0xFFFFFFFFU ), + pos_wrapped( false ) { buffer[dictionary_size-1] = 0; } // prev_byte of first byte ~LZ_decoder() { delete[] buffer; } @@ -284,7 +287,8 @@ void LZ_decoder::flush_data() if( std::fwrite( buffer + stream_pos, 1, size, stdout ) != size ) { std::fprintf( stderr, "Write error: %s\n", std::strerror( errno ) ); std::exit( 1 ); } - if( pos >= dictionary_size ) { partial_data_pos += pos; pos = 0; } + if( pos >= dictionary_size ) + { partial_data_pos += pos; pos = 0; pos_wrapped = true; } stream_pos = pos; } } @@ -380,7 +384,7 @@ bool LZ_decoder::decode_member() // Returns false if error } } state.set_match(); - if( rep0 >= dictionary_size || rep0 >= data_position() ) + if( rep0 >= dictionary_size || ( rep0 >= pos && !pos_wrapped ) ) { flush_data(); return false; } } for( int i = 0; i < len; ++i ) put_byte( peek( rep0 ) ); @@ -402,7 +406,7 @@ int main( const int argc, const char * const argv[] ) "It is not safe to use lzd for any real work.\n" "\nUsage: %s < file.lz > file\n", argv[0] ); std::printf( "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2015 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2016 Antonio Diaz Diaz.\n" "This is free software: you are free to change and redistribute it.\n" "There is NO WARRANTY, to the extent permitted by law.\n" "Report bugs to lzip-bug@nongnu.org\n" diff --git a/testsuite/check.sh b/testsuite/check.sh index cf0a940..7ebec69 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013-2015 Antonio Diaz Diaz. +# Copyright (C) 2013-2016 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute and modify it. From 29dc774230c57158e5de9e18db2eaf58f766cdd5 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 14:59:00 +0100 Subject: [PATCH 04/10] Adding upstream version 0.9. Signed-off-by: Daniel Baumann --- ChangeLog | 5 +++++ INSTALL | 2 +- Makefile.in | 9 +++++++-- NEWS | 6 +++--- configure | 6 +++--- lzd.cc | 12 ++++++++++-- testsuite/check.sh | 2 +- 7 files changed, 30 insertions(+), 12 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3aaf64a..c7c931f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2016-05-10 Antonio Diaz Diaz + + * Version 0.9 released. + * configure: Avoid warning on some shells when testing for g++. + 2016-01-23 Antonio Diaz Diaz * Version 0.8 released. diff --git a/INSTALL b/INSTALL index 014ab3f..dc2e623 100644 --- a/INSTALL +++ b/INSTALL @@ -1,7 +1,7 @@ Requirements ------------ You will need a C++ compiler. -I use gcc 4.9.1 and 4.1.2, but the code should compile with any +I use gcc 5.3.0 and 4.1.2, but the code should compile with any standards compliant compiler. Gcc is available at http://gcc.gnu.org. diff --git a/Makefile.in b/Makefile.in index b125b52..42cdcc0 100644 --- a/Makefile.in +++ b/Makefile.in @@ -5,6 +5,7 @@ INSTALL_PROGRAM = $(INSTALL) -m 755 INSTALL_DATA = $(INSTALL) -m 644 INSTALL_DIR = $(INSTALL) -d -m 755 SHELL = /bin/sh +CAN_RUN_INSTALLINFO = $(SHELL) -c "install-info --version" > /dev/null 2>&1 objs = lzd.o @@ -61,7 +62,9 @@ install-info : if [ ! -d "$(DESTDIR)$(infodir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(infodir)" ; fi -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info"* $(INSTALL_DATA) $(VPATH)/doc/$(pkgname).info "$(DESTDIR)$(infodir)/$(pkgname).info" - -install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$(pkgname).info" + -if $(CAN_RUN_INSTALLINFO) ; then \ + install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$(pkgname).info" ; \ + fi install-info-compress : install-info lzip -v -9 "$(DESTDIR)$(infodir)/$(pkgname).info" @@ -80,7 +83,9 @@ uninstall-bin : -rm -f "$(DESTDIR)$(bindir)/$(progname)" uninstall-info : - -install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$(pkgname).info" + -if $(CAN_RUN_INSTALLINFO) ; then \ + install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$(pkgname).info" ; \ + fi -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info"* uninstall-man : diff --git a/NEWS b/NEWS index 57ca1b3..085da72 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,4 @@ -Changes in version 0.8: +Changes in version 0.9: -It has been documented that lzip does not use the LZMA parameter -'literal_pos_state_bits'. +A configure warning happening on some shells when testing for g++ has +been fixed. diff --git a/configure b/configure index 83d3447..226e838 100755 --- a/configure +++ b/configure @@ -6,7 +6,7 @@ # to copy, distribute and modify it. pkgname=lzd -pkgversion=0.8 +pkgversion=0.9 progname=lzd srctrigger=lzd.cc @@ -26,8 +26,8 @@ CXXFLAGS='-Wall -W -O2' LDFLAGS= # checking whether we are using GNU C++. -${CXX} --version > /dev/null 2>&1 -if [ $? != 0 ] ; then +if /bin/sh -c "${CXX} --version" > /dev/null 2>&1 ; then true +else CXX=c++ CXXFLAGS='-W -O2' fi diff --git a/lzd.cc b/lzd.cc index 5f8dcdc..56dce37 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,8 +1,16 @@ /* Lzd - Educational decompressor for the lzip format Copyright (C) 2013-2016 Antonio Diaz Diaz. - This program is free software: you have unlimited permission - to copy, distribute and modify it. + This program is free software. Redistribution and use in source and + binary forms, with or without modification, are permitted provided + that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of diff --git a/testsuite/check.sh b/testsuite/check.sh index 7ebec69..f03377f 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -19,7 +19,7 @@ fi if [ -d tmp ] ; then rm -rf tmp ; fi mkdir tmp -cd "${objdir}"/tmp +cd "${objdir}"/tmp || framework_failure in="${testdir}"/test.txt in_lz="${testdir}"/test.txt.lz From dcb57f45d56c4194ab7507104ca0697c9034808b Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 15:01:40 +0100 Subject: [PATCH 05/10] Adding upstream version 1.0. Signed-off-by: Daniel Baumann --- COPYING | 17 +++++++++ ChangeLog | 8 ++++- INSTALL | 2 +- Makefile.in | 5 +-- NEWS | 7 ++-- README | 12 +++---- configure | 21 +++++++----- lzd.cc | 78 ++++++++++++++++++++---------------------- testsuite/check.sh | 48 +++++++++++++++++++------- testsuite/test.txt.lz | Bin 7376 -> 7376 bytes 10 files changed, 124 insertions(+), 74 deletions(-) create mode 100644 COPYING diff --git a/COPYING b/COPYING new file mode 100644 index 0000000..5b9d8b9 --- /dev/null +++ b/COPYING @@ -0,0 +1,17 @@ + Lzd - Educational decompressor for the lzip format + Copyright (C) Antonio Diaz Diaz. + + This program is free software. Redistribution and use in source and + binary forms, with or without modification, are permitted provided + that the following conditions are met: + + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. diff --git a/ChangeLog b/ChangeLog index c7c931f..380d736 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2017-05-02 Antonio Diaz Diaz + + * Version 1.0 released. + * lzd.cc: Minor code improvements. + * testsuite/check.sh: A POSIX shell is required to run the tests. + 2016-05-10 Antonio Diaz Diaz * Version 0.9 released. @@ -43,7 +49,7 @@ * Version 0.1 released. -Copyright (C) 2013-2016 Antonio Diaz Diaz. +Copyright (C) 2013-2017 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute and diff --git a/INSTALL b/INSTALL index dc2e623..c245516 100644 --- a/INSTALL +++ b/INSTALL @@ -50,7 +50,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2016 Antonio Diaz Diaz. +Copyright (C) 2013-2017 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/Makefile.in b/Makefile.in index 42cdcc0..471ff4b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -95,16 +95,17 @@ dist : doc ln -sf $(VPATH) $(DISTNAME) tar -Hustar --owner=root --group=root -cvf $(DISTNAME).tar \ $(DISTNAME)/AUTHORS \ + $(DISTNAME)/COPYING \ $(DISTNAME)/ChangeLog \ $(DISTNAME)/INSTALL \ $(DISTNAME)/Makefile.in \ $(DISTNAME)/NEWS \ $(DISTNAME)/README \ $(DISTNAME)/configure \ + $(DISTNAME)/*.cc \ $(DISTNAME)/testsuite/check.sh \ $(DISTNAME)/testsuite/test.txt \ - $(DISTNAME)/testsuite/test.txt.lz \ - $(DISTNAME)/*.cc + $(DISTNAME)/testsuite/test.txt.lz rm -f $(DISTNAME) lzip -v -9 $(DISTNAME).tar diff --git a/NEWS b/NEWS index 085da72..2f713df 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,5 @@ -Changes in version 0.9: +Changes in version 1.0: -A configure warning happening on some shells when testing for g++ has -been fixed. +Minor code improvements have been made. + +The tests have been improved. diff --git a/README b/README index ae73fc1..e16763e 100644 --- a/README +++ b/README @@ -24,11 +24,11 @@ availability: merging of damaged copies of a file. * The lzip format is as simple as possible (but not simpler). The - lzip manual provides the code of a simple decompressor along with a - detailed explanation of how it works, so that with the only help of - the lzip manual it would be possible for a digital archaeologist to - extract the data from a lzip file long after quantum computers - eventually render LZMA obsolete. + lzip manual provides the source code of a simple decompressor along + with a detailed explanation of how it works, so that with the only + help of the lzip manual it would be possible for a digital + archaeologist to extract the data from a lzip file long after + quantum computers eventually render LZMA obsolete. * Additionally the lzip reference implementation is copylefted, which guarantees that it will remain free forever. @@ -45,7 +45,7 @@ range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2016 Antonio Diaz Diaz. +Copyright (C) 2013-2017 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/configure b/configure index 226e838..7499b98 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2016 Antonio Diaz Diaz. +# Copyright (C) 2013-2017 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute and modify it. pkgname=lzd -pkgversion=0.9 +pkgversion=1.0 progname=lzd srctrigger=lzd.cc @@ -26,11 +26,11 @@ CXXFLAGS='-Wall -W -O2' LDFLAGS= # checking whether we are using GNU C++. -if /bin/sh -c "${CXX} --version" > /dev/null 2>&1 ; then true -else +/bin/sh -c "${CXX} --version" > /dev/null 2>&1 || + { CXX=c++ - CXXFLAGS='-W -O2' -fi + CXXFLAGS=-O2 + } # Loop over all args args= @@ -52,9 +52,12 @@ while [ $# != 0 ] ; do # Process the options case ${option} in --help | -h) - echo "Usage: configure [options]" + echo "Usage: $0 [OPTION]... [VAR=VALUE]..." echo - echo "Options: [defaults in brackets]" + echo "To assign makefile variables (e.g., CXX, CXXFLAGS...), specify them as" + echo "arguments to configure in the form VAR=VALUE." + echo + echo "Options and variables: [defaults in brackets]" echo " -h, --help display this help and exit" echo " -V, --version output version information and exit" echo " --srcdir=DIR find the sources in DIR [. or ..]" @@ -165,7 +168,7 @@ echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2016 Antonio Diaz Diaz. +# Copyright (C) 2013-2017 Antonio Diaz Diaz. # This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission diff --git a/lzd.cc b/lzd.cc index 56dce37..6fd536a 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2016 Antonio Diaz Diaz. + Copyright (C) 2013-2017 Antonio Diaz Diaz. This program is free software. Redistribution and use in source and binary forms, with or without modification, are permitted provided @@ -150,10 +150,10 @@ public: uint8_t get_byte() { return std::getc( stdin ); } - int decode( const int num_bits ) + unsigned decode( const int num_bits ) { - int symbol = 0; - for( int i = 0; i < num_bits; ++i ) + unsigned symbol = 0; + for( int i = num_bits; i > 0; --i ) { range >>= 1; symbol <<= 1; @@ -164,9 +164,9 @@ public: return symbol; } - int decode_bit( Bit_model & bm ) + unsigned decode_bit( Bit_model & bm ) { - int symbol; + unsigned symbol; const uint32_t bound = ( range >> bit_model_total_bits ) * bm.probability; if( code < bound ) { @@ -186,18 +186,18 @@ public: return symbol; } - int decode_tree( Bit_model bm[], const int num_bits ) + unsigned decode_tree( Bit_model bm[], const int num_bits ) { - int symbol = 1; + unsigned symbol = 1; for( int i = 0; i < num_bits; ++i ) symbol = ( symbol << 1 ) | decode_bit( bm[symbol] ); return symbol - (1 << num_bits); } - int decode_tree_reversed( Bit_model bm[], const int num_bits ) + unsigned decode_tree_reversed( Bit_model bm[], const int num_bits ) { - int symbol = decode_tree( bm, num_bits ); - int reversed_symbol = 0; + unsigned symbol = decode_tree( bm, num_bits ); + unsigned reversed_symbol = 0; for( int i = 0; i < num_bits; ++i ) { reversed_symbol = ( reversed_symbol << 1 ) | ( symbol & 1 ); @@ -206,14 +206,13 @@ public: return reversed_symbol; } - int decode_matched( Bit_model bm[], const int match_byte ) + unsigned decode_matched( Bit_model bm[], const unsigned match_byte ) { - Bit_model * const bm1 = bm + 0x100; - int symbol = 1; + unsigned symbol = 1; for( int i = 7; i >= 0; --i ) { - const int match_bit = ( match_byte >> i ) & 1; - const int bit = decode_bit( bm1[(match_bit<<8)+symbol] ); + const unsigned match_bit = ( match_byte >> i ) & 1; + const unsigned bit = decode_bit( bm[symbol+(match_bit<<8)+0x100] ); symbol = ( symbol << 1 ) | bit; if( match_bit != bit ) { @@ -225,7 +224,7 @@ public: return symbol & 0xFF; } - int decode_len( Len_model & lm, const int pos_state ) + unsigned decode_len( Len_model & lm, const int pos_state ) { if( decode_bit( lm.choice1 ) == 0 ) return decode_tree( lm.bm_low[pos_state], len_low_bits ); @@ -253,9 +252,9 @@ class LZ_decoder uint8_t peek( const unsigned distance ) const { - unsigned i = pos - distance - 1; - if( pos <= distance ) i += dictionary_size; - return buffer[i]; + if( pos > distance ) return buffer[pos - distance - 1]; + if( pos_wrapped ) return buffer[dictionary_size + pos - distance - 1]; + return 0; // prev_byte of first byte } void put_byte( const uint8_t b ) @@ -274,7 +273,7 @@ public: stream_pos( 0 ), crc_( 0xFFFFFFFFU ), pos_wrapped( false ) - { buffer[dictionary_size-1] = 0; } // prev_byte of first byte + {} ~LZ_decoder() { delete[] buffer; } @@ -312,13 +311,13 @@ bool LZ_decoder::decode_member() // Returns false if error Bit_model bm_rep2[State::states]; Bit_model bm_len[State::states][pos_states]; Bit_model bm_dis_slot[len_states][1<= start_dis_model ) { + const unsigned dis_slot = rep0; const int direct_bits = ( dis_slot >> 1 ) - 1; rep0 = ( 2 | ( dis_slot & 1 ) ) << direct_bits; if( dis_slot < end_dis_model ) - rep0 += rdec.decode_tree_reversed( bm_dis + rep0 - dis_slot - 1, + rep0 += rdec.decode_tree_reversed( bm_dis + ( rep0 - dis_slot ), direct_bits ); else { @@ -414,7 +412,7 @@ int main( const int argc, const char * const argv[] ) "It is not safe to use lzd for any real work.\n" "\nUsage: %s < file.lz > file\n", argv[0] ); std::printf( "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2016 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2017 Antonio Diaz Diaz.\n" "This is free software: you are free to change and redistribute it.\n" "There is NO WARRANTY, to the extent permitted by law.\n" "Report bugs to lzip-bug@nongnu.org\n" @@ -429,7 +427,7 @@ int main( const int argc, const char * const argv[] ) for( bool first_member = true; ; first_member = false ) { - File_header header; + File_header header; // verify header for( int i = 0; i < 6; ++i ) header[i] = std::getc( stdin ); if( std::feof( stdin ) || std::memcmp( header, "LZIP\x01", 5 ) != 0 ) { @@ -444,11 +442,11 @@ int main( const int argc, const char * const argv[] ) { std::fputs( "Invalid dictionary size in member header.\n", stderr ); return 2; } - LZ_decoder decoder( dict_size ); + LZ_decoder decoder( dict_size ); // decode LZMA stream if( !decoder.decode_member() ) { std::fputs( "Data error\n", stderr ); return 2; } - File_trailer trailer; + File_trailer trailer; // verify trailer for( int i = 0; i < 20; ++i ) trailer[i] = std::getc( stdin ); unsigned crc = 0; for( int i = 3; i >= 0; --i ) { crc <<= 8; crc += trailer[i]; } diff --git a/testsuite/check.sh b/testsuite/check.sh index f03377f..71cabc4 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013-2016 Antonio Diaz Diaz. +# Copyright (C) 2013-2017 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute and modify it. @@ -17,6 +17,13 @@ if [ ! -f "${LZIP}" ] || [ ! -x "${LZIP}" ] ; then exit 1 fi +[ -e "${LZIP}" ] 2> /dev/null || + { + echo "$0: a POSIX shell is required to run the tests" + echo "Try bash -c \"$0 $1 $2\"" + exit 1 + } + if [ -d tmp ] ; then rm -rf tmp ; fi mkdir tmp cd "${objdir}"/tmp || framework_failure @@ -24,24 +31,41 @@ cd "${objdir}"/tmp || framework_failure in="${testdir}"/test.txt in_lz="${testdir}"/test.txt.lz fail=0 +test_failed() { fail=1 ; printf " $1" ; [ -z "$2" ] || printf "($2)" ; } printf "testing lzd-%s..." "$2" "${LZIP}" < "${in}" 2> /dev/null -if [ $? = 2 ] ; then printf . ; else printf - ; fail=1 ; fi -dd if="${in_lz}" bs=1 count=6 2> /dev/null | "${LZIP}" 2> /dev/null -if [ $? = 2 ] ; then printf . ; else printf - ; fail=1 ; fi -dd if="${in_lz}" bs=1 count=20 2> /dev/null | "${LZIP}" > /dev/null 2>&1 -if [ $? = 2 ] ; then printf . ; else printf - ; fail=1 ; fi +[ $? = 2 ] || test_failed $LINENO -"${LZIP}" < "${in_lz}" > copy || fail=1 -cmp "${in}" copy || fail=1 -printf . +"${LZIP}" < "${in_lz}" > copy || test_failed $LINENO +cmp "${in}" copy || test_failed $LINENO cat "${in}" "${in}" > in2 || framework_failure -cat "${in_lz}" "${in_lz}" | "${LZIP}" > copy2 || fail=1 -cmp in2 copy2 || fail=1 -printf . +cat "${in_lz}" "${in_lz}" > in2.lz || framework_failure +"${LZIP}" < in2.lz > copy2 || test_failed $LINENO +cmp in2 copy2 || test_failed $LINENO + +printf "\ntesting bad input..." + +cat "${in_lz}" "${in_lz}" "${in_lz}" > in3.lz || framework_failure +if dd if=in3.lz of=trunc.lz bs=14752 count=1 2> /dev/null && + [ -e trunc.lz ] && cmp in2.lz trunc.lz > /dev/null 2>&1 ; then +# can't detect truncated header of non-first member + for i in 6 20 14734 14758 ; do + dd if=in3.lz of=trunc.lz bs=$i count=1 2> /dev/null + "${LZIP}" < trunc.lz > out 2> /dev/null + [ $? = 2 ] || test_failed $LINENO $i + done +else + printf "\nwarning: skipping truncation test: 'dd' does not work on your system." +fi + +cat "${in_lz}" > ingin.lz || framework_failure +printf "g" >> ingin.lz || framework_failure +cat "${in_lz}" >> ingin.lz || framework_failure +"${LZIP}" < ingin.lz > copy || test_failed $LINENO +cmp "${in}" copy || test_failed $LINENO echo if [ ${fail} = 0 ] ; then diff --git a/testsuite/test.txt.lz b/testsuite/test.txt.lz index 41d2e39999a92cd871d646a4ae00ba25ef067cc4..22cea6e4d2a58b4dcb006541dcdb8defabba0cbb 100644 GIT binary patch delta 15 Wcmca$dBKv+C(1K`@%=`&Q!)TBtOex& delta 15 Wcmca$dBKv+C(1K`@xw;8Q!)TBu?6M; From 6a0f9dafa8adf78edec6ebec22a186143ed4ddfe Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 15:04:05 +0100 Subject: [PATCH 06/10] Adding upstream version 1.1. Signed-off-by: Daniel Baumann --- ChangeLog | 13 +++-- INSTALL | 6 +-- NEWS | 9 ++-- README | 19 ++++--- configure | 16 +++--- lzd.cc | 126 ++++++++++++++++++++++----------------------- testsuite/check.sh | 6 ++- 7 files changed, 104 insertions(+), 91 deletions(-) diff --git a/ChangeLog b/ChangeLog index 380d736..eae5639 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,8 +1,15 @@ +2019-01-11 Antonio Diaz Diaz + + * Version 1.1 released. + * File_* renamed to Lzip_*. + * lzd.cc: Compile on DOS with DJGPP. + * configure: Accept appending to CXXFLAGS, 'CXXFLAGS+=OPTIONS'. + 2017-05-02 Antonio Diaz Diaz * Version 1.0 released. * lzd.cc: Minor code improvements. - * testsuite/check.sh: A POSIX shell is required to run the tests. + * check.sh: A POSIX shell is required to run the tests. 2016-05-10 Antonio Diaz Diaz @@ -32,7 +39,7 @@ 2013-08-01 Antonio Diaz Diaz * Version 0.4 released. - * testsuite/check.sh: Removed '/dev/full' from tests. + * check.sh: Removed '/dev/full' from tests. 2013-07-24 Antonio Diaz Diaz @@ -49,7 +56,7 @@ * Version 0.1 released. -Copyright (C) 2013-2017 Antonio Diaz Diaz. +Copyright (C) 2013-2019 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute and diff --git a/INSTALL b/INSTALL index c245516..55b2603 100644 --- a/INSTALL +++ b/INSTALL @@ -1,8 +1,8 @@ Requirements ------------ You will need a C++ compiler. -I use gcc 5.3.0 and 4.1.2, but the code should compile with any -standards compliant compiler. +I use gcc 5.3.0 and 4.1.2, but the code should compile with any standards +compliant compiler. Gcc is available at http://gcc.gnu.org. @@ -50,7 +50,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2017 Antonio Diaz Diaz. +Copyright (C) 2013-2019 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/NEWS b/NEWS index 2f713df..b22edc2 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,8 @@ -Changes in version 1.0: +Changes in version 1.1: -Minor code improvements have been made. +All 'File_*' identifiers have been renamed to 'Lzip_*'. -The tests have been improved. +Lzd now should compile on DOS with DJGPP. + +The configure script now accepts appending options to CXXFLAGS using the +syntax 'CXXFLAGS+=OPTIONS'. diff --git a/README b/README index e16763e..4b639c6 100644 --- a/README +++ b/README @@ -13,22 +13,21 @@ correctly decompress the concatenation of two or more compressed files. The result is the concatenation of the corresponding decompressed data. Integrity of such concatenated compressed input is also verified. -The lzip file format is designed for data sharing and long-term -archiving, taking into account both data integrity and decoder -availability: +The lzip file format is designed for data sharing and long-term archiving, +taking into account both data integrity and decoder availability: * The lzip format provides very safe integrity checking and some data - recovery means. The lziprecover program can repair bit-flip errors + recovery means. The lziprecover program can repair bit flip errors (one of the most common forms of data corruption) in lzip files, and provides data recovery capabilities, including error-checked merging of damaged copies of a file. * The lzip format is as simple as possible (but not simpler). The - lzip manual provides the source code of a simple decompressor along - with a detailed explanation of how it works, so that with the only - help of the lzip manual it would be possible for a digital - archaeologist to extract the data from a lzip file long after - quantum computers eventually render LZMA obsolete. + lzip manual provides the source code of a simple decompressor + along with a detailed explanation of how it works, so that with + the only help of the lzip manual it would be possible for a + digital archaeologist to extract the data from a lzip file long + after quantum computers eventually render LZMA obsolete. * Additionally the lzip reference implementation is copylefted, which guarantees that it will remain free forever. @@ -45,7 +44,7 @@ range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2017 Antonio Diaz Diaz. +Copyright (C) 2013-2019 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute and modify it. diff --git a/configure b/configure index 7499b98..a4e000e 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2017 Antonio Diaz Diaz. +# Copyright (C) 2013-2019 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute and modify it. pkgname=lzd -pkgversion=1.0 +pkgversion=1.1 progname=lzd srctrigger=lzd.cc @@ -70,6 +70,7 @@ while [ $# != 0 ] ; do echo " CXX=COMPILER C++ compiler to use [${CXX}]" echo " CPPFLAGS=OPTIONS command line options for the preprocessor [${CPPFLAGS}]" echo " CXXFLAGS=OPTIONS command line options for the C++ compiler [${CXXFLAGS}]" + echo " CXXFLAGS+=OPTIONS append options to the current value of CXXFLAGS" echo " LDFLAGS=OPTIONS command line options for the linker [${LDFLAGS}]" echo exit 0 ;; @@ -93,10 +94,11 @@ while [ $# != 0 ] ; do --mandir=*) mandir=${optarg} ;; --no-create) no_create=yes ;; - CXX=*) CXX=${optarg} ;; - CPPFLAGS=*) CPPFLAGS=${optarg} ;; - CXXFLAGS=*) CXXFLAGS=${optarg} ;; - LDFLAGS=*) LDFLAGS=${optarg} ;; + CXX=*) CXX=${optarg} ;; + CPPFLAGS=*) CPPFLAGS=${optarg} ;; + CXXFLAGS=*) CXXFLAGS=${optarg} ;; + CXXFLAGS+=*) CXXFLAGS="${CXXFLAGS} ${optarg}" ;; + LDFLAGS=*) LDFLAGS=${optarg} ;; --*) echo "configure: WARNING: unrecognized option: '${option}'" 1>&2 ;; @@ -168,7 +170,7 @@ echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2017 Antonio Diaz Diaz. +# Copyright (C) 2013-2019 Antonio Diaz Diaz. # This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission diff --git a/lzd.cc b/lzd.cc index 6fd536a..503bc36 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2017 Antonio Diaz Diaz. + Copyright (C) 2013-2019 Antonio Diaz Diaz. This program is free software. Redistribution and use in source and binary forms, with or without modification, are permitted provided @@ -29,7 +29,7 @@ #include #include #include -#if defined(__MSVCRT__) || defined(__OS2__) || defined(_MSC_VER) +#if defined(__MSVCRT__) || defined(__OS2__) || defined(__DJGPP__) #include #include #endif @@ -130,9 +130,9 @@ public: const CRC32 crc32; -typedef uint8_t File_header[6]; // 0-3 magic, 4 version, 5 coded_dict_size +typedef uint8_t Lzip_header[6]; // 0-3 magic, 4 version, 5 coded_dict_size -typedef uint8_t File_trailer[20]; +typedef uint8_t Lzip_trailer[20]; // 0-3 CRC32 of the uncompressed data // 4-11 size of the uncompressed data // 12-19 member size including header and trailer @@ -326,6 +326,7 @@ bool LZ_decoder::decode_member() // Returns false if error const int pos_state = data_position() & pos_state_mask; if( rdec.decode_bit( bm_match[state()][pos_state] ) == 0 ) // 1st bit { + // literal byte const uint8_t prev_byte = peek( 0 ); const int literal_state = prev_byte >> ( 8 - literal_context_bits ); Bit_model * const bm = bm_literal[literal_state]; @@ -334,67 +335,66 @@ bool LZ_decoder::decode_member() // Returns false if error else put_byte( rdec.decode_matched( bm, peek( rep0 ) ) ); state.set_char(); + continue; } - else // match or repeated match + // match or repeated match + int len; + if( rdec.decode_bit( bm_rep[state()] ) != 0 ) // 2nd bit { - int len; - if( rdec.decode_bit( bm_rep[state()] ) != 0 ) // 2nd bit + if( rdec.decode_bit( bm_rep0[state()] ) == 0 ) // 3rd bit { - if( rdec.decode_bit( bm_rep0[state()] ) == 0 ) // 3rd bit - { - if( rdec.decode_bit( bm_len[state()][pos_state] ) == 0 ) // 4th bit - { state.set_short_rep(); put_byte( peek( rep0 ) ); continue; } - } + if( rdec.decode_bit( bm_len[state()][pos_state] ) == 0 ) // 4th bit + { state.set_short_rep(); put_byte( peek( rep0 ) ); continue; } + } + else + { + unsigned distance; + if( rdec.decode_bit( bm_rep1[state()] ) == 0 ) // 4th bit + distance = rep1; else { - unsigned distance; - if( rdec.decode_bit( bm_rep1[state()] ) == 0 ) // 4th bit - distance = rep1; + if( rdec.decode_bit( bm_rep2[state()] ) == 0 ) // 5th bit + distance = rep2; else - { - if( rdec.decode_bit( bm_rep2[state()] ) == 0 ) // 5th bit - distance = rep2; - else - { distance = rep3; rep3 = rep2; } - rep2 = rep1; - } - rep1 = rep0; - rep0 = distance; + { distance = rep3; rep3 = rep2; } + rep2 = rep1; } - state.set_rep(); - len = min_match_len + rdec.decode_len( rep_len_model, pos_state ); + rep1 = rep0; + rep0 = distance; } - else // match - { - rep3 = rep2; rep2 = rep1; rep1 = rep0; - len = min_match_len + rdec.decode_len( match_len_model, pos_state ); - const int len_state = std::min( len - min_match_len, len_states - 1 ); - rep0 = rdec.decode_tree( bm_dis_slot[len_state], dis_slot_bits ); - if( rep0 >= start_dis_model ) - { - const unsigned dis_slot = rep0; - const int direct_bits = ( dis_slot >> 1 ) - 1; - rep0 = ( 2 | ( dis_slot & 1 ) ) << direct_bits; - if( dis_slot < end_dis_model ) - rep0 += rdec.decode_tree_reversed( bm_dis + ( rep0 - dis_slot ), - direct_bits ); - else - { - rep0 += rdec.decode( direct_bits - dis_align_bits ) << dis_align_bits; - rep0 += rdec.decode_tree_reversed( bm_align, dis_align_bits ); - if( rep0 == 0xFFFFFFFFU ) // marker found - { - flush_data(); - return ( len == min_match_len ); // End Of Stream marker - } - } - } - state.set_match(); - if( rep0 >= dictionary_size || ( rep0 >= pos && !pos_wrapped ) ) - { flush_data(); return false; } - } - for( int i = 0; i < len; ++i ) put_byte( peek( rep0 ) ); + state.set_rep(); + len = min_match_len + rdec.decode_len( rep_len_model, pos_state ); } + else // match + { + rep3 = rep2; rep2 = rep1; rep1 = rep0; + len = min_match_len + rdec.decode_len( match_len_model, pos_state ); + const int len_state = std::min( len - min_match_len, len_states - 1 ); + rep0 = rdec.decode_tree( bm_dis_slot[len_state], dis_slot_bits ); + if( rep0 >= start_dis_model ) + { + const unsigned dis_slot = rep0; + const int direct_bits = ( dis_slot >> 1 ) - 1; + rep0 = ( 2 | ( dis_slot & 1 ) ) << direct_bits; + if( dis_slot < end_dis_model ) + rep0 += rdec.decode_tree_reversed( bm_dis + ( rep0 - dis_slot ), + direct_bits ); + else + { + rep0 += rdec.decode( direct_bits - dis_align_bits ) << dis_align_bits; + rep0 += rdec.decode_tree_reversed( bm_align, dis_align_bits ); + if( rep0 == 0xFFFFFFFFU ) // marker found + { + flush_data(); + return ( len == min_match_len ); // End Of Stream marker + } + } + } + state.set_match(); + if( rep0 >= dictionary_size || ( rep0 >= pos && !pos_wrapped ) ) + { flush_data(); return false; } + } + for( int i = 0; i < len; ++i ) put_byte( peek( rep0 ) ); } flush_data(); return false; @@ -412,7 +412,7 @@ int main( const int argc, const char * const argv[] ) "It is not safe to use lzd for any real work.\n" "\nUsage: %s < file.lz > file\n", argv[0] ); std::printf( "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2017 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2019 Antonio Diaz Diaz.\n" "This is free software: you are free to change and redistribute it.\n" "There is NO WARRANTY, to the extent permitted by law.\n" "Report bugs to lzip-bug@nongnu.org\n" @@ -420,14 +420,14 @@ int main( const int argc, const char * const argv[] ) return 0; } -#if defined(__MSVCRT__) || defined(__OS2__) || defined(_MSC_VER) - setmode( fileno( stdin ), O_BINARY ); - setmode( fileno( stdout ), O_BINARY ); +#if defined(__MSVCRT__) || defined(__OS2__) || defined(__DJGPP__) + setmode( STDIN_FILENO, O_BINARY ); + setmode( STDOUT_FILENO, O_BINARY ); #endif for( bool first_member = true; ; first_member = false ) { - File_header header; // verify header + Lzip_header header; // verify header for( int i = 0; i < 6; ++i ) header[i] = std::getc( stdin ); if( std::feof( stdin ) || std::memcmp( header, "LZIP\x01", 5 ) != 0 ) { @@ -446,7 +446,7 @@ int main( const int argc, const char * const argv[] ) if( !decoder.decode_member() ) { std::fputs( "Data error\n", stderr ); return 2; } - File_trailer trailer; // verify trailer + Lzip_trailer trailer; // verify trailer for( int i = 0; i < 20; ++i ) trailer[i] = std::getc( stdin ); unsigned crc = 0; for( int i = 3; i >= 0; --i ) { crc <<= 8; crc += trailer[i]; } @@ -457,7 +457,7 @@ int main( const int argc, const char * const argv[] ) } if( std::fclose( stdout ) != 0 ) - { std::fprintf( stderr, "Can't close stdout: %s\n", std::strerror( errno ) ); + { std::fprintf( stderr, "Error closing stdout: %s\n", std::strerror( errno ) ); return 1; } return 0; } diff --git a/testsuite/check.sh b/testsuite/check.sh index 71cabc4..eb83163 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh -# check script for Lzd - Educational decompressor for lzip files -# Copyright (C) 2013-2017 Antonio Diaz Diaz. +# check script for Lzd - Educational decompressor for the lzip format +# Copyright (C) 2013-2019 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute and modify it. @@ -60,12 +60,14 @@ if dd if=in3.lz of=trunc.lz bs=14752 count=1 2> /dev/null && else printf "\nwarning: skipping truncation test: 'dd' does not work on your system." fi +rm -f in2.lz in3.lz trunc.lz out || framework_failure cat "${in_lz}" > ingin.lz || framework_failure printf "g" >> ingin.lz || framework_failure cat "${in_lz}" >> ingin.lz || framework_failure "${LZIP}" < ingin.lz > copy || test_failed $LINENO cmp "${in}" copy || test_failed $LINENO +rm -f copy ingin.lz || framework_failure echo if [ ${fail} = 0 ] ; then From 5fa8d2a83dcc65886fb092a83831fa5f6326fbd2 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 15:06:16 +0100 Subject: [PATCH 07/10] Adding upstream version 1.2. Signed-off-by: Daniel Baumann --- AUTHORS | 7 +-- COPYING | 26 ++++---- ChangeLog | 21 +++++-- INSTALL | 14 ++--- Makefile.in | 9 ++- NEWS | 18 ++++-- README | 64 ++++++++++--------- configure | 25 ++++---- lzd.cc | 129 +++++++++++++++++++++++---------------- testsuite/check.sh | 32 ++++++++-- testsuite/fox.lz | Bin 0 -> 80 bytes testsuite/fox_bcrc.lz | Bin 0 -> 80 bytes testsuite/fox_bm.lz | Bin 0 -> 80 bytes testsuite/fox_crc0.lz | Bin 0 -> 80 bytes testsuite/fox_das46.lz | Bin 0 -> 80 bytes testsuite/fox_de20.lz | Bin 0 -> 80 bytes testsuite/fox_mes81.lz | Bin 0 -> 80 bytes testsuite/fox_s11.lz | Bin 0 -> 80 bytes testsuite/fox_v2.lz | Bin 0 -> 80 bytes testsuite/test_em.txt.lz | Bin 0 -> 14024 bytes 20 files changed, 207 insertions(+), 138 deletions(-) create mode 100644 testsuite/fox.lz create mode 100644 testsuite/fox_bcrc.lz create mode 100644 testsuite/fox_bm.lz create mode 100644 testsuite/fox_crc0.lz create mode 100644 testsuite/fox_das46.lz create mode 100644 testsuite/fox_de20.lz create mode 100644 testsuite/fox_mes81.lz create mode 100644 testsuite/fox_s11.lz create mode 100644 testsuite/fox_v2.lz create mode 100644 testsuite/test_em.txt.lz diff --git a/AUTHORS b/AUTHORS index a7b5945..27ceba5 100644 --- a/AUTHORS +++ b/AUTHORS @@ -1,7 +1,6 @@ Lzd was written by Antonio Diaz Diaz. The ideas embodied in lzd are due to (at least) the following people: -Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for -the definition of Markov chains), G.N.N. Martin (for the definition of -range encoding), and Igor Pavlov (for putting all the above together in -LZMA). +Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for the +definition of Markov chains), G.N.N. Martin (for the definition of range +encoding), and Igor Pavlov (for putting all the above together in LZMA). diff --git a/COPYING b/COPYING index 5b9d8b9..0105f19 100644 --- a/COPYING +++ b/COPYING @@ -1,17 +1,17 @@ - Lzd - Educational decompressor for the lzip format - Copyright (C) Antonio Diaz Diaz. + Lzd - Educational decompressor for the lzip format + Copyright (C) Antonio Diaz Diaz. - This program is free software. Redistribution and use in source and - binary forms, with or without modification, are permitted provided - that the following conditions are met: + This program is free software. Redistribution and use in source and + binary forms, with or without modification, are permitted provided + that the following conditions are met: - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions, and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions, and the following disclaimer in the + documentation and/or other materials provided with the distribution. - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. diff --git a/ChangeLog b/ChangeLog index eae5639..b17c9db 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,16 @@ +2021-01-04 Antonio Diaz Diaz + + * Version 1.2 released. + * lzd.cc (main): Verify also mismatches in member size. + Accept and ignore the option '-d' for compatibility with zutils. + Remove warning about "lzd not safe for real work". + Print license notice. + * testsuite: Add 10 new test files. + 2019-01-11 Antonio Diaz Diaz * Version 1.1 released. - * File_* renamed to Lzip_*. + * Rename File_* to Lzip_*. * lzd.cc: Compile on DOS with DJGPP. * configure: Accept appending to CXXFLAGS, 'CXXFLAGS+=OPTIONS'. @@ -19,7 +28,7 @@ 2016-01-23 Antonio Diaz Diaz * Version 0.8 released. - * Documented that lzip does not use 'literal_pos_state_bits'. + * Document that lzip does not use 'literal_pos_state_bits'. 2015-07-07 Antonio Diaz Diaz @@ -39,7 +48,7 @@ 2013-08-01 Antonio Diaz Diaz * Version 0.4 released. - * check.sh: Removed '/dev/full' from tests. + * check.sh: Remove '/dev/full' from tests. 2013-07-24 Antonio Diaz Diaz @@ -49,15 +58,15 @@ 2013-05-06 Antonio Diaz Diaz * Version 0.2 released. - * main.c: Added a missing '#include' for OS/2. + * main.c: Add a missing '#include' for OS/2. 2013-03-21 Antonio Diaz Diaz * Version 0.1 released. -Copyright (C) 2013-2019 Antonio Diaz Diaz. +Copyright (C) 2013-2021 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, -but just in case, you have unlimited permission to copy, distribute and +but just in case, you have unlimited permission to copy, distribute, and modify it. diff --git a/INSTALL b/INSTALL index 55b2603..f2a5025 100644 --- a/INSTALL +++ b/INSTALL @@ -1,7 +1,7 @@ Requirements ------------ -You will need a C++ compiler. -I use gcc 5.3.0 and 4.1.2, but the code should compile with any standards +You will need a C++11 compiler. (gcc 3.3.6 or newer is recommended). +I use gcc 6.1.0 and 4.1.2, but the code should compile with any standards compliant compiler. Gcc is available at http://gcc.gnu.org. @@ -36,10 +36,10 @@ the main archive. Another way ----------- You can also compile lzd into a separate directory. -To do this, you must use a version of 'make' that supports the 'VPATH' -variable, such as GNU 'make'. 'cd' to the directory where you want the +To do this, you must use a version of 'make' that supports the variable +'VPATH', such as GNU 'make'. 'cd' to the directory where you want the object files and executables to go and run the 'configure' script. -'configure' automatically checks for the source code in '.', in '..' and +'configure' automatically checks for the source code in '.', in '..', and in the directory that 'configure' is in. 'configure' recognizes the option '--srcdir=DIR' to control where to @@ -50,7 +50,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2019 Antonio Diaz Diaz. +Copyright (C) 2013-2021 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, -distribute and modify it. +distribute, and modify it. diff --git a/Makefile.in b/Makefile.in index 471ff4b..b2f6d55 100644 --- a/Makefile.in +++ b/Makefile.in @@ -63,7 +63,7 @@ install-info : -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info"* $(INSTALL_DATA) $(VPATH)/doc/$(pkgname).info "$(DESTDIR)$(infodir)/$(pkgname).info" -if $(CAN_RUN_INSTALLINFO) ; then \ - install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$(pkgname).info" ; \ + install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$(pkgname).info" ; \ fi install-info-compress : install-info @@ -84,7 +84,7 @@ uninstall-bin : uninstall-info : -if $(CAN_RUN_INSTALLINFO) ; then \ - install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$(pkgname).info" ; \ + install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$(pkgname).info" ; \ fi -rm -f "$(DESTDIR)$(infodir)/$(pkgname).info"* @@ -105,7 +105,10 @@ dist : doc $(DISTNAME)/*.cc \ $(DISTNAME)/testsuite/check.sh \ $(DISTNAME)/testsuite/test.txt \ - $(DISTNAME)/testsuite/test.txt.lz + $(DISTNAME)/testsuite/fox.lz \ + $(DISTNAME)/testsuite/fox_*.lz \ + $(DISTNAME)/testsuite/test.txt.lz \ + $(DISTNAME)/testsuite/test_em.txt.lz rm -f $(DISTNAME) lzip -v -9 $(DISTNAME).tar diff --git a/NEWS b/NEWS index b22edc2..f1893b8 100644 --- a/NEWS +++ b/NEWS @@ -1,8 +1,16 @@ -Changes in version 1.1: +Changes in version 1.2: -All 'File_*' identifiers have been renamed to 'Lzip_*'. +Mismatches in member size are now verified. Lzd is now compliant with the +lzip specification; it verifies the 3 integrity factors. -Lzd now should compile on DOS with DJGPP. +Lzd now accepts (and ignores) the option '-d'. This allows it to be used as +argument to the option '--lz' of the tools from the zutils package. -The configure script now accepts appending options to CXXFLAGS using the -syntax 'CXXFLAGS+=OPTIONS'. +The warning about "lzd not safe for real work" has been removed. +(Lzd is safe, just not very convenient to use). + +10 new test files have been added to the testsuite. + +The source code of lzd is now used as a reference in the description of the +media type 'application/lzip'. +See http://datatracker.ietf.org/doc/draft-diaz-lzip diff --git a/README b/README index 4b639c6..fa5ff44 100644 --- a/README +++ b/README @@ -2,52 +2,60 @@ Description Lzd is a simplified decompressor for the lzip format with an educational purpose. Studying its source is a good first step to understand how lzip -works. It is not safe to use lzd for any real work. +works. -The source of lzd is used in the lzip manual as a reference decompressor -in the description of the lzip file format. Reading the lzip manual will -help you understand the source. +The source of lzd is used in the lzip manual as a reference decompressor in +the description of the lzip file format. Reading the lzip manual will help +you understand the source. Lzd is compliant with the lzip specification; it +verifies the 3 integrity factors. -Lzd decompresses from standard input to standard output. Lzd will -correctly decompress the concatenation of two or more compressed files. -The result is the concatenation of the corresponding decompressed data. -Integrity of such concatenated compressed input is also verified. +The source of lzd is also used as a reference in the description of the +media type 'application/lzip'. +See http://datatracker.ietf.org/doc/draft-diaz-lzip + +Lzd decompresses from standard input to standard output. It accepts (and +ignores) the option '-d' for compatibility with other lzip tools. In +particular, accepting the option '-d' allows lzd to be used as argument to +the option '--lz' of the tools from the zutils package. + +Lzd will correctly decompress the concatenation of two or more compressed +files. The result is the concatenation of the corresponding decompressed +data. Integrity of such concatenated compressed input is also verified. The lzip file format is designed for data sharing and long-term archiving, taking into account both data integrity and decoder availability: * The lzip format provides very safe integrity checking and some data - recovery means. The lziprecover program can repair bit flip errors - (one of the most common forms of data corruption) in lzip files, - and provides data recovery capabilities, including error-checked - merging of damaged copies of a file. + recovery means. The program lziprecover can repair bit flip errors + (one of the most common forms of data corruption) in lzip files, and + provides data recovery capabilities, including error-checked merging + of damaged copies of a file. - * The lzip format is as simple as possible (but not simpler). The - lzip manual provides the source code of a simple decompressor - along with a detailed explanation of how it works, so that with - the only help of the lzip manual it would be possible for a - digital archaeologist to extract the data from a lzip file long - after quantum computers eventually render LZMA obsolete. + * The lzip format is as simple as possible (but not simpler). The lzip + manual provides the source code of a simple decompressor along with a + detailed explanation of how it works, so that with the only help of the + lzip manual it would be possible for a digital archaeologist to extract + the data from a lzip file long after quantum computers eventually + render LZMA obsolete. * Additionally the lzip reference implementation is copylefted, which guarantees that it will remain free forever. -A nice feature of the lzip format is that a corrupt byte is easier to -repair the nearer it is from the beginning of the file. Therefore, with -the help of lziprecover, losing an entire archive just because of a -corrupt byte near the beginning is a thing of the past. +A nice feature of the lzip format is that a corrupt byte is easier to repair +the nearer it is from the beginning of the file. Therefore, with the help of +lziprecover, losing an entire archive just because of a corrupt byte near +the beginning is a thing of the past. The ideas embodied in lzd are due to (at least) the following people: -Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for -the definition of Markov chains), G.N.N. Martin (for the definition of -range encoding), and Igor Pavlov (for putting all the above together in -LZMA). +Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for the +definition of Markov chains), G.N.N. Martin (for the definition of range +encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2019 Antonio Diaz Diaz. +Copyright (C) 2013-2021 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, -distribute and modify it. +distribute, and modify it. The file Makefile.in is a data file used by configure to produce the Makefile. It has the same copyright owner and permissions that configure diff --git a/configure b/configure index a4e000e..a1f7471 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2019 Antonio Diaz Diaz. +# Copyright (C) 2013-2021 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission -# to copy, distribute and modify it. +# to copy, distribute, and modify it. pkgname=lzd -pkgversion=1.1 +pkgversion=1.2 progname=lzd srctrigger=lzd.cc @@ -26,11 +26,7 @@ CXXFLAGS='-Wall -W -O2' LDFLAGS= # checking whether we are using GNU C++. -/bin/sh -c "${CXX} --version" > /dev/null 2>&1 || - { - CXX=c++ - CXXFLAGS=-O2 - } +/bin/sh -c "${CXX} --version" > /dev/null 2>&1 || { CXX=c++ ; CXXFLAGS=-O2 ; } # Loop over all args args= @@ -42,11 +38,12 @@ while [ $# != 0 ] ; do shift # Add the argument quoted to args - args="${args} \"${option}\"" + if [ -z "${args}" ] ; then args="\"${option}\"" + else args="${args} \"${option}\"" ; fi # Split out the argument for options that take them case ${option} in - *=*) optarg=`echo ${option} | sed -e 's,^[^=]*=,,;s,/$,,'` ;; + *=*) optarg=`echo "${option}" | sed -e 's,^[^=]*=,,;s,/$,,'` ;; esac # Process the options @@ -125,7 +122,7 @@ if [ -z "${srcdir}" ] ; then if [ ! -r "${srcdir}/${srctrigger}" ] ; then srcdir=.. ; fi if [ ! -r "${srcdir}/${srctrigger}" ] ; then ## the sed command below emulates the dirname command - srcdir=`echo $0 | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` + srcdir=`echo "$0" | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` fi fi @@ -148,7 +145,7 @@ if [ -z "${no_create}" ] ; then # Run this file to recreate the current configuration. # # This script is free software: you have unlimited permission -# to copy, distribute and modify it. +# to copy, distribute, and modify it. exec /bin/sh $0 ${args} --no-create EOF @@ -170,11 +167,11 @@ echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2019 Antonio Diaz Diaz. +# Copyright (C) 2013-2021 Antonio Diaz Diaz. # This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission -# to copy, distribute and modify it. +# to copy, distribute, and modify it. pkgname = ${pkgname} pkgversion = ${pkgversion} diff --git a/lzd.cc b/lzd.cc index 503bc36..f7572b2 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,25 +1,25 @@ -/* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2019 Antonio Diaz Diaz. +/* Lzd - Educational decompressor for the lzip format + Copyright (C) 2013-2021 Antonio Diaz Diaz. - This program is free software. Redistribution and use in source and - binary forms, with or without modification, are permitted provided - that the following conditions are met: + This program is free software. Redistribution and use in source and + binary forms, with or without modification, are permitted provided + that the following conditions are met: - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. + 1. Redistributions of source code must retain the above copyright + notice, this list of conditions, and the following disclaimer. - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. + 2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions, and the following disclaimer in the + documentation and/or other materials provided with the distribution. - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. */ /* - Exit status: 0 for a normal exit, 1 for environmental problems - (file not found, invalid flags, I/O errors, etc), 2 to indicate a - corrupt or invalid input file. + Exit status: 0 for a normal exit, 1 for environmental problems + (file not found, invalid flags, I/O errors, etc), 2 to indicate a + corrupt or invalid input file. */ #include @@ -47,7 +47,7 @@ public: void set_char() { - static const int next[states] = { 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 4, 5 }; + const int next[states] = { 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 4, 5 }; st = next[st]; } void set_match() { st = ( st < 7 ) ? 7 : 10; } @@ -69,7 +69,7 @@ enum { dis_slot_bits = 6, start_dis_model = 4, end_dis_model = 14, - modeled_distances = 1 << (end_dis_model / 2), // 128 + modeled_distances = 1 << ( end_dis_model / 2 ), // 128 dis_align_bits = 4, dis_align_size = 1 << dis_align_bits, @@ -130,8 +130,9 @@ public: const CRC32 crc32; -typedef uint8_t Lzip_header[6]; // 0-3 magic, 4 version, 5 coded_dict_size - +typedef uint8_t Lzip_header[6]; // 0-3 magic bytes + // 4 version + // 5 coded dictionary size typedef uint8_t Lzip_trailer[20]; // 0-3 CRC32 of the uncompressed data // 4-11 size of the uncompressed data @@ -139,16 +140,18 @@ typedef uint8_t Lzip_trailer[20]; class Range_decoder { + unsigned long long member_pos; uint32_t code; uint32_t range; public: - Range_decoder() : code( 0 ), range( 0xFFFFFFFFU ) + Range_decoder() : member_pos( 6 ), code( 0 ), range( 0xFFFFFFFFU ) { - for( int i = 0; i < 5; ++i ) code = (code << 8) | get_byte(); + for( int i = 0; i < 5; ++i ) code = ( code << 8 ) | get_byte(); } - uint8_t get_byte() { return std::getc( stdin ); } + uint8_t get_byte() { ++member_pos; return std::getc( stdin ); } + unsigned long long member_position() const { return member_pos; } unsigned decode( const int num_bits ) { @@ -159,7 +162,7 @@ public: symbol <<= 1; if( code >= range ) { code -= range; symbol |= 1; } if( range <= 0x00FFFFFFU ) // normalize - { range <<= 8; code = (code << 8) | get_byte(); } + { range <<= 8; code = ( code << 8 ) | get_byte(); } } return symbol; } @@ -171,7 +174,8 @@ public: if( code < bound ) { range = bound; - bm.probability += (bit_model_total - bm.probability) >> bit_model_move_bits; + bm.probability += + ( bit_model_total - bm.probability ) >> bit_model_move_bits; symbol = 0; } else @@ -182,7 +186,7 @@ public: symbol = 1; } if( range <= 0x00FFFFFFU ) // normalize - { range <<= 8; code = (code << 8) | get_byte(); } + { range <<= 8; code = ( code << 8 ) | get_byte(); } return symbol; } @@ -191,7 +195,7 @@ public: unsigned symbol = 1; for( int i = 0; i < num_bits; ++i ) symbol = ( symbol << 1 ) | decode_bit( bm[symbol] ); - return symbol - (1 << num_bits); + return symbol - ( 1 << num_bits ); } unsigned decode_tree_reversed( Bit_model bm[], const int num_bits ) @@ -278,7 +282,11 @@ public: ~LZ_decoder() { delete[] buffer; } unsigned crc() const { return crc_ ^ 0xFFFFFFFFU; } - unsigned long long data_position() const { return partial_data_pos + pos; } + unsigned long long data_position() const + { return partial_data_pos + pos; } + uint8_t get_byte() { return rdec.get_byte(); } + unsigned long long member_position() const + { return rdec.member_position(); } bool decode_member(); }; @@ -290,7 +298,6 @@ void LZ_decoder::flush_data() { const unsigned size = pos - stream_pos; crc32.update_buf( crc_, buffer + stream_pos, size ); - errno = 0; if( std::fwrite( buffer + stream_pos, 1, size, stdout ) != size ) { std::fprintf( stderr, "Write error: %s\n", std::strerror( errno ) ); std::exit( 1 ); } @@ -301,7 +308,7 @@ void LZ_decoder::flush_data() } -bool LZ_decoder::decode_member() // Returns false if error +bool LZ_decoder::decode_member() // Returns false if error { Bit_model bm_literal[1< 1 ) + if( argc > 2 || ( argc == 2 && std::strcmp( argv[1], "-d" ) != 0 ) ) { - std::printf( "Lzd %s - Educational decompressor for the lzip format.\n", - PROGVERSION ); - std::printf( "Study the source to learn how a lzip decompressor works.\n" - "See the lzip manual for an explanation of the code.\n" - "It is not safe to use lzd for any real work.\n" - "\nUsage: %s < file.lz > file\n", argv[0] ); - std::printf( "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2019 Antonio Diaz Diaz.\n" - "This is free software: you are free to change and redistribute it.\n" - "There is NO WARRANTY, to the extent permitted by law.\n" - "Report bugs to lzip-bug@nongnu.org\n" - "Lzd home page: http://www.nongnu.org/lzip/lzd.html\n" ); + std::printf( + "Lzd %s - Educational decompressor for the lzip format.\n" + "Study the source to learn how a lzip decompressor works.\n" + "See the lzip manual for an explanation of the code.\n" + "\nUsage: %s [-d] < file.lz > file\n" + "Lzd decompresses from standard input to standard output.\n" + "\nCopyright (C) 2021 Antonio Diaz Diaz.\n" + "License 2-clause BSD.\n" + "This is free software: you are free to change and redistribute it.\n" + "There is NO WARRANTY, to the extent permitted by law.\n" + "Report bugs to lzip-bug@nongnu.org\n" + "Lzd home page: http://www.nongnu.org/lzip/lzd.html\n", + PROGVERSION, argv[0] ); return 0; } @@ -432,9 +441,9 @@ int main( const int argc, const char * const argv[] ) if( std::feof( stdin ) || std::memcmp( header, "LZIP\x01", 5 ) != 0 ) { if( first_member ) - { std::fputs( "Bad magic number (file not in lzip format).\n", stderr ); - return 2; } - break; + { std::fputs( "Bad magic number (file not in lzip format).\n", + stderr ); return 2; } + break; // ignore trailing data } unsigned dict_size = 1 << ( header[5] & 0x1F ); dict_size -= ( dict_size / 16 ) * ( ( header[5] >> 5 ) & 7 ); @@ -447,17 +456,29 @@ int main( const int argc, const char * const argv[] ) { std::fputs( "Data error\n", stderr ); return 2; } Lzip_trailer trailer; // verify trailer - for( int i = 0; i < 20; ++i ) trailer[i] = std::getc( stdin ); + for( int i = 0; i < 20; ++i ) trailer[i] = decoder.get_byte(); + int retval = 0; unsigned crc = 0; - for( int i = 3; i >= 0; --i ) { crc <<= 8; crc += trailer[i]; } + for( int i = 3; i >= 0; --i ) crc = ( crc << 8 ) + trailer[i]; + if( crc != decoder.crc() ) + { std::fputs( "CRC mismatch\n", stderr ); retval = 2; } + unsigned long long data_size = 0; - for( int i = 11; i >= 4; --i ) { data_size <<= 8; data_size += trailer[i]; } - if( crc != decoder.crc() || data_size != decoder.data_position() ) - { std::fputs( "CRC error\n", stderr ); return 2; } + for( int i = 11; i >= 4; --i ) + data_size = ( data_size << 8 ) + trailer[i]; + if( data_size != decoder.data_position() ) + { std::fputs( "Data size mismatch\n", stderr ); retval = 2; } + + unsigned long long member_size = 0; + for( int i = 19; i >= 12; --i ) + member_size = ( member_size << 8 ) + trailer[i]; + if( member_size != decoder.member_position() ) + { std::fputs( "Member size mismatch\n", stderr ); retval = 2; } + if( retval ) return retval; } if( std::fclose( stdout ) != 0 ) - { std::fprintf( stderr, "Error closing stdout: %s\n", std::strerror( errno ) ); - return 1; } + { std::fprintf( stderr, "Error closing stdout: %s\n", + std::strerror( errno ) ); return 1; } return 0; } diff --git a/testsuite/check.sh b/testsuite/check.sh index eb83163..c1f86e6 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,9 +1,9 @@ #! /bin/sh # check script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2019 Antonio Diaz Diaz. +# Copyright (C) 2013-2021 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission -# to copy, distribute and modify it. +# to copy, distribute, and modify it. LC_ALL=C export LC_ALL @@ -30,6 +30,8 @@ cd "${objdir}"/tmp || framework_failure in="${testdir}"/test.txt in_lz="${testdir}"/test.txt.lz +in_em="${testdir}"/test_em.txt.lz +fox_lz="${testdir}"/fox.lz fail=0 test_failed() { fail=1 ; printf " $1" ; [ -z "$2" ] || printf "($2)" ; } @@ -38,16 +40,38 @@ printf "testing lzd-%s..." "$2" "${LZIP}" < "${in}" 2> /dev/null [ $? = 2 ] || test_failed $LINENO -"${LZIP}" < "${in_lz}" > copy || test_failed $LINENO -cmp "${in}" copy || test_failed $LINENO +for i in "${in_lz}" "${in_em}" ; do + "${LZIP}" < "$i" > copy || test_failed $LINENO "$i" + cmp "${in}" copy || test_failed $LINENO "$i" +done cat "${in}" "${in}" > in2 || framework_failure cat "${in_lz}" "${in_lz}" > in2.lz || framework_failure "${LZIP}" < in2.lz > copy2 || test_failed $LINENO cmp in2 copy2 || test_failed $LINENO +cat in2.lz > copy2.lz || framework_failure +printf "\ngarbage" >> copy2.lz || framework_failure +"${LZIP}" -d < copy2.lz > copy2 || test_failed $LINENO +cmp in2 copy2 || test_failed $LINENO +rm -f in2 copy2 copy2.lz || framework_failure + printf "\ntesting bad input..." +for i in fox_bm.lz fox_v2.lz fox_s11.lz fox_de20.lz \ + fox_bcrc.lz fox_crc0.lz fox_das46.lz fox_mes81.lz ; do + "${LZIP}" < "${testdir}"/$i > /dev/null 2>&1 + [ $? = 2 ] || test_failed $LINENO $i +done + +"${LZIP}" < "${fox_lz}" > fox || test_failed $LINENO +for i in fox_bcrc.lz fox_crc0.lz fox_das46.lz fox_mes81.lz ; do + "${LZIP}" < "${testdir}"/$i > out 2> /dev/null + [ $? = 2 ] || test_failed $LINENO $i + cmp fox out || test_failed $LINENO $i +done +rm -f fox out || framework_failure + cat "${in_lz}" "${in_lz}" "${in_lz}" > in3.lz || framework_failure if dd if=in3.lz of=trunc.lz bs=14752 count=1 2> /dev/null && [ -e trunc.lz ] && cmp in2.lz trunc.lz > /dev/null 2>&1 ; then diff --git a/testsuite/fox.lz b/testsuite/fox.lz new file mode 100644 index 0000000000000000000000000000000000000000..509da8268a3fd054415089a646cdcfd00d3eee7a GIT binary patch literal 80 zcmeZ?@(f_)VbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E07J|k>Hq)$ literal 0 HcmV?d00001 diff --git a/testsuite/fox_bcrc.lz b/testsuite/fox_bcrc.lz new file mode 100644 index 0000000000000000000000000000000000000000..8f6a7c4af4b808a1ed873b58d5d9a343a722edcd GIT binary patch literal 80 zcmeZ?@(f_)VbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFb)#z-wIw2nc}E07Kv&>i_@% literal 0 HcmV?d00001 diff --git a/testsuite/fox_bm.lz b/testsuite/fox_bm.lz new file mode 100644 index 0000000000000000000000000000000000000000..d71914fc3f364f84cfce1138cdd6c636ef309ea3 GIT binary patch literal 80 zcmeZ?$_!xSVbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E08NY^3IG5A literal 0 HcmV?d00001 diff --git a/testsuite/fox_crc0.lz b/testsuite/fox_crc0.lz new file mode 100644 index 0000000000000000000000000000000000000000..1abe92689f2fb57212633f41962e53f4297bd5a2 GIT binary patch literal 80 zcmeZ?@(f_)VbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU bIqmVA>95u)|NqywfB^(_!6XAi0F(v*7bP5d literal 0 HcmV?d00001 diff --git a/testsuite/fox_das46.lz b/testsuite/fox_das46.lz new file mode 100644 index 0000000000000000000000000000000000000000..43ed9f9503c4e8c298e6bf671f669b56e24162a2 GIT binary patch literal 80 zcmeZ?@(f_)VbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-v7Q2nc}E07Kj!>i_@% literal 0 HcmV?d00001 diff --git a/testsuite/fox_de20.lz b/testsuite/fox_de20.lz new file mode 100644 index 0000000000000000000000000000000000000000..10949d888f0e1c630fc860b3a8c8eb0bee7f77bf GIT binary patch literal 80 zcmeZ?@(f_)VbGG|Sj4QF_R+iI=pxpCde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E07H--=>Px# literal 0 HcmV?d00001 diff --git a/testsuite/fox_mes81.lz b/testsuite/fox_mes81.lz new file mode 100644 index 0000000000000000000000000000000000000000..d50ef2e2fa7a5160a77c814344218585e865f266 GIT binary patch literal 80 zcmeZ?@(f_)VbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2ndAI07KLs>i_@% literal 0 HcmV?d00001 diff --git a/testsuite/fox_s11.lz b/testsuite/fox_s11.lz new file mode 100644 index 0000000000000000000000000000000000000000..dca909c62a44e1b011404dbd5afe0af47c3bb6e7 GIT binary patch literal 80 zcmeZ?@(f_)X3&!2Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E07HQu=>Px# literal 0 HcmV?d00001 diff --git a/testsuite/fox_v2.lz b/testsuite/fox_v2.lz new file mode 100644 index 0000000000000000000000000000000000000000..8620981714096152fff6673aa04060f251bdad44 GIT binary patch literal 80 zcmeZ?@(f_&VbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E07Mub>i_@% literal 0 HcmV?d00001 diff --git a/testsuite/test_em.txt.lz b/testsuite/test_em.txt.lz new file mode 100644 index 0000000000000000000000000000000000000000..7e96250d9ec70bc7d8cb173f438c76be447e6b6f GIT binary patch literal 14024 zcmb7~Ly#~4lVsbrZQHhO+qP}nwr$(CZQJht_TQb^!`^1=Qc)3g%8I(YOc^an1wa^p z;D6u${tW>9zeV!jqs;%_i332e{Szlg{U9R$^emnpP=->;y-J2_NFLo;6abfiRy$%i z;1u`u$LCGROi}}VAX@hA><%1+po5w@DJyf3l$=$r?jKb!fSy)n`3%Yd=-O|aMmvx} z(_25sQF~*#S!d^N#(dfqI#&Mt6bCWEkcPQ-^@r`OYq8}?DB(W0u339!Bw(F*D} z9nEy7I3-T(Lf+Vw#Nyel4m`=31_S~|T628lhp|*6s(1GgF5#BXaWChE>-e>hLJxp< z80t5rbm`)E9A%~S4JrM~7v4zNn9js$&tkFrWD4)sNR|0OP$G52O(kc0yPk@p1auv$ z+H<3yS#I)!kx9%5t&20ww99~&=J`s#!=n}&t`76!suXV@dcSAT1R9~BE&Ueu8+txY zMFruAwF*@)jr4@CLGJaJ;R`JkS*9eQFP6^>X72c#itJq%0>1{PFFvsDV~V_&MGxA> z4bOf$Q?FhABF5DmYfl)CGR6#`S6;`GoBF9LXsU?-2H^LcPJ7_&KE2j(^?Y0|Iugb; z;tl2eepab=(&OV+o(>M~YFIzyD{hlgW+gZ?I7(Y@{QdqJc+#FY3;Xl9_gxE-!V7Y< zi|G2&c>25jureBCC!!|})?iTPVif*`bAr0t@u2%_7!xOrMELo2PYaEGEe~>_!nwBd zkX9wc9&H5w;$7B15WcKsh=HK`Ss}&Z+=-Vm-L5#w_CP0BT%HB~z(wqxr9-OfaH*hC zNP+mf^Qa%{V18r_>ulkj*w@VLhLh+kf#Ma6Emf1#*`KHu2Oq`YFWYBK5fNNJ!X*taZe9 zo;bClvb)Cw+o1sXDM3AGAy_pTV!!sZYFr`B4Of?zDk$J$p~zw;_#FLt%YxG9IrwPQ zf$28YD0X%WnY@o!zjD9Ub{PrqCC&Bwd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ri!P1c! z@amIW0!WTy%3Q4#+1PR`CJ?sy%Z(`K#y=>3AoZvnZUC4kDI<#FXp`bfjx*@<{Pk!f%Edl9u}g&Z0M2;t+xt-Rk*3V%`_y3W^E=Po+Yt&u4no3i8p|q>DpblDpLW4 zBRVZljPXg&IP|&VutC=P+t0IPj!NdZJq?B1>cnZ6vKpZJspn zL4O(P_U^iCQ>mb<%Ifa8HRryIOmEhn)4cB?zX_O@3puXW!Rb?&9qkgJviGj`Az;0` zgIv~PzbO~-ghRaHg{9GhGuBQ-r0Ax>#a>WicZ|xS4=k?{4 zZR(~xR9ori>wdMvUN5absJ1!?<%U-kLPf3FD-*1x`Nzn8g$T*JDl#p*RWy|PcQ=#- zTLW&2Fex?v{!V+fKZv%#js81LW&i(y Gt^OBPlQ$#) literal 0 HcmV?d00001 From 4ebeeeb19116cb0d4b0e49b47eb07c5814b22e5a Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 15:08:05 +0100 Subject: [PATCH 08/10] Adding upstream version 1.3. Signed-off-by: Daniel Baumann --- AUTHORS | 2 +- ChangeLog | 9 +++++++-- INSTALL | 15 ++++++++------- Makefile.in | 2 +- NEWS | 19 ++++--------------- README | 18 +++++++++--------- configure | 12 ++++++------ lzd.cc | 21 +++++++++++---------- testsuite/check.sh | 15 ++++++++------- 9 files changed, 55 insertions(+), 58 deletions(-) diff --git a/AUTHORS b/AUTHORS index 27ceba5..48f7099 100644 --- a/AUTHORS +++ b/AUTHORS @@ -1,6 +1,6 @@ Lzd was written by Antonio Diaz Diaz. The ideas embodied in lzd are due to (at least) the following people: -Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for the +Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrei Markov (for the definition of Markov chains), G.N.N. Martin (for the definition of range encoding), and Igor Pavlov (for putting all the above together in LZMA). diff --git a/ChangeLog b/ChangeLog index b17c9db..042b251 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2022-10-24 Antonio Diaz Diaz + + * Version 1.3 released. + * lzd.cc (Range_decoder): Discard first byte explicitly. + 2021-01-04 Antonio Diaz Diaz * Version 1.2 released. @@ -12,7 +17,7 @@ * Version 1.1 released. * Rename File_* to Lzip_*. * lzd.cc: Compile on DOS with DJGPP. - * configure: Accept appending to CXXFLAGS, 'CXXFLAGS+=OPTIONS'. + * configure: Accept appending to CXXFLAGS; 'CXXFLAGS+=OPTIONS'. 2017-05-02 Antonio Diaz Diaz @@ -65,7 +70,7 @@ * Version 0.1 released. -Copyright (C) 2013-2021 Antonio Diaz Diaz. +Copyright (C) 2013-2022 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute, and diff --git a/INSTALL b/INSTALL index f2a5025..ecf03f1 100644 --- a/INSTALL +++ b/INSTALL @@ -1,7 +1,8 @@ Requirements ------------ -You will need a C++11 compiler. (gcc 3.3.6 or newer is recommended). -I use gcc 6.1.0 and 4.1.2, but the code should compile with any standards +You will need a C++98 compiler with support for 'long long'. +(gcc 3.3.6 or newer is recommended). +I use gcc 6.1.0 and 3.3.6, but the code should compile with any standards compliant compiler. Gcc is available at http://gcc.gnu.org. @@ -14,8 +15,8 @@ Procedure or lzip -cd lzd[version].tar.lz | tar -xf - -This creates the directory ./lzd[version] containing the source from -the main archive. +This creates the directory ./lzd[version] containing the source code +extracted from the archive. 2. Change to lzd directory and run configure. (Try 'configure --help' for usage instructions). @@ -42,15 +43,15 @@ object files and executables to go and run the 'configure' script. 'configure' automatically checks for the source code in '.', in '..', and in the directory that 'configure' is in. -'configure' recognizes the option '--srcdir=DIR' to control where to -look for the sources. Usually 'configure' can determine that directory +'configure' recognizes the option '--srcdir=DIR' to control where to look +for the source code. Usually 'configure' can determine that directory automatically. After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2021 Antonio Diaz Diaz. +Copyright (C) 2013-2022 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute, and modify it. diff --git a/Makefile.in b/Makefile.in index b2f6d55..ced714d 100644 --- a/Makefile.in +++ b/Makefile.in @@ -19,7 +19,7 @@ objs = lzd.o all : $(progname) $(progname) : $(objs) - $(CXX) $(LDFLAGS) $(CXXFLAGS) -o $@ $(objs) + $(CXX) $(CXXFLAGS) $(LDFLAGS) -o $@ $(objs) %.o : %.cc $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $< diff --git a/NEWS b/NEWS index f1893b8..2416499 100644 --- a/NEWS +++ b/NEWS @@ -1,16 +1,5 @@ -Changes in version 1.2: +Changes in version 1.3: -Mismatches in member size are now verified. Lzd is now compliant with the -lzip specification; it verifies the 3 integrity factors. - -Lzd now accepts (and ignores) the option '-d'. This allows it to be used as -argument to the option '--lz' of the tools from the zutils package. - -The warning about "lzd not safe for real work" has been removed. -(Lzd is safe, just not very convenient to use). - -10 new test files have been added to the testsuite. - -The source code of lzd is now used as a reference in the description of the -media type 'application/lzip'. -See http://datatracker.ietf.org/doc/draft-diaz-lzip +Lzd now discards the first byte of the LZMA stream explicity (instead of +shifting 1 extra byte in the initialization of 'code') to make the intent +clearer. diff --git a/README b/README index fa5ff44..fae23bc 100644 --- a/README +++ b/README @@ -1,15 +1,15 @@ Description Lzd is a simplified decompressor for the lzip format with an educational -purpose. Studying its source is a good first step to understand how lzip -works. +purpose. Studying its source code is a good first step to understand how +lzip works. Lzd is written in C++. -The source of lzd is used in the lzip manual as a reference decompressor in -the description of the lzip file format. Reading the lzip manual will help -you understand the source. Lzd is compliant with the lzip specification; it -verifies the 3 integrity factors. +The source code of lzd is used in the lzip manual as a reference +decompressor in the description of the lzip file format. Reading the lzip +manual will help you understand the source code. Lzd is compliant with the +lzip specification; it verifies the 3 integrity factors. -The source of lzd is also used as a reference in the description of the +The source code of lzd is also used as a reference in the description of the media type 'application/lzip'. See http://datatracker.ietf.org/doc/draft-diaz-lzip @@ -47,12 +47,12 @@ lziprecover, losing an entire archive just because of a corrupt byte near the beginning is a thing of the past. The ideas embodied in lzd are due to (at least) the following people: -Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrey Markov (for the +Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrei Markov (for the definition of Markov chains), G.N.N. Martin (for the definition of range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2021 Antonio Diaz Diaz. +Copyright (C) 2013-2022 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute, and modify it. diff --git a/configure b/configure index a1f7471..cf10b79 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2021 Antonio Diaz Diaz. +# Copyright (C) 2013-2022 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute, and modify it. pkgname=lzd -pkgversion=1.2 +pkgversion=1.3 progname=lzd srctrigger=lzd.cc @@ -57,7 +57,7 @@ while [ $# != 0 ] ; do echo "Options and variables: [defaults in brackets]" echo " -h, --help display this help and exit" echo " -V, --version output version information and exit" - echo " --srcdir=DIR find the sources in DIR [. or ..]" + echo " --srcdir=DIR find the source code in DIR [. or ..]" echo " --prefix=DIR install into DIR [${prefix}]" echo " --exec-prefix=DIR base directory for arch-dependent files [${exec_prefix}]" echo " --bindir=DIR user executables directory [${bindir}]" @@ -115,7 +115,7 @@ while [ $# != 0 ] ; do fi done -# Find the source files, if location was not specified. +# Find the source code, if location was not specified. srcdirtext= if [ -z "${srcdir}" ] ; then srcdirtext="or . or .." ; srcdir=. @@ -127,7 +127,7 @@ if [ -z "${srcdir}" ] ; then fi if [ ! -r "${srcdir}/${srctrigger}" ] ; then - echo "configure: Can't find sources in ${srcdir} ${srcdirtext}" 1>&2 + echo "configure: Can't find source code in ${srcdir} ${srcdirtext}" 1>&2 echo "configure: (At least ${srctrigger} is missing)." 1>&2 exit 1 fi @@ -167,7 +167,7 @@ echo "LDFLAGS = ${LDFLAGS}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2021 Antonio Diaz Diaz. +# Copyright (C) 2013-2022 Antonio Diaz Diaz. # This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission diff --git a/lzd.cc b/lzd.cc index f7572b2..9e1c3b8 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2021 Antonio Diaz Diaz. + Copyright (C) 2013-2022 Antonio Diaz Diaz. This program is free software. Redistribution and use in source and binary forms, with or without modification, are permitted provided @@ -18,8 +18,8 @@ */ /* Exit status: 0 for a normal exit, 1 for environmental problems - (file not found, invalid flags, I/O errors, etc), 2 to indicate a - corrupt or invalid input file. + (file not found, invalid command line options, I/O errors, etc), 2 to + indicate a corrupt or invalid input file. */ #include @@ -29,7 +29,7 @@ #include #include #include -#if defined(__MSVCRT__) || defined(__OS2__) || defined(__DJGPP__) +#if defined __MSVCRT__ || defined __OS2__ || defined __DJGPP__ #include #include #endif @@ -147,7 +147,8 @@ class Range_decoder public: Range_decoder() : member_pos( 6 ), code( 0 ), range( 0xFFFFFFFFU ) { - for( int i = 0; i < 5; ++i ) code = ( code << 8 ) | get_byte(); + get_byte(); // discard first byte of the LZMA stream + for( int i = 0; i < 4; ++i ) code = ( code << 8 ) | get_byte(); } uint8_t get_byte() { ++member_pos; return std::getc( stdin ); } @@ -180,8 +181,8 @@ public: } else { - range -= bound; code -= bound; + range -= bound; bm.probability -= bm.probability >> bit_model_move_bits; symbol = 1; } @@ -308,7 +309,7 @@ void LZ_decoder::flush_data() } -bool LZ_decoder::decode_member() // Returns false if error +bool LZ_decoder::decode_member() // Return false if error { Bit_model bm_literal[1< file\n" "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2021 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2022 Antonio Diaz Diaz.\n" "License 2-clause BSD.\n" "This is free software: you are free to change and redistribute it.\n" "There is NO WARRANTY, to the extent permitted by law.\n" @@ -429,7 +430,7 @@ int main( const int argc, const char * const argv[] ) return 0; } -#if defined(__MSVCRT__) || defined(__OS2__) || defined(__DJGPP__) +#if defined __MSVCRT__ || defined __OS2__ || defined __DJGPP__ setmode( STDIN_FILENO, O_BINARY ); setmode( STDOUT_FILENO, O_BINARY ); #endif diff --git a/testsuite/check.sh b/testsuite/check.sh index c1f86e6..33ffb8a 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2021 Antonio Diaz Diaz. +# Copyright (C) 2013-2022 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute, and modify it. @@ -46,11 +46,11 @@ for i in "${in_lz}" "${in_em}" ; do done cat "${in}" "${in}" > in2 || framework_failure -cat "${in_lz}" "${in_lz}" > in2.lz || framework_failure -"${LZIP}" < in2.lz > copy2 || test_failed $LINENO +cat "${in_lz}" "${in_lz}" | "${LZIP}" > copy2 || test_failed $LINENO cmp in2 copy2 || test_failed $LINENO +rm -f copy2 || framework_failure -cat in2.lz > copy2.lz || framework_failure +cat "${in_lz}" "${in_lz}" > copy2.lz || framework_failure printf "\ngarbage" >> copy2.lz || framework_failure "${LZIP}" -d < copy2.lz > copy2 || test_failed $LINENO cmp in2 copy2 || test_failed $LINENO @@ -72,24 +72,25 @@ for i in fox_bcrc.lz fox_crc0.lz fox_das46.lz fox_mes81.lz ; do done rm -f fox out || framework_failure +cat "${in_lz}" "${in_lz}" > in2.lz || framework_failure cat "${in_lz}" "${in_lz}" "${in_lz}" > in3.lz || framework_failure if dd if=in3.lz of=trunc.lz bs=14752 count=1 2> /dev/null && [ -e trunc.lz ] && cmp in2.lz trunc.lz > /dev/null 2>&1 ; then # can't detect truncated header of non-first member for i in 6 20 14734 14758 ; do dd if=in3.lz of=trunc.lz bs=$i count=1 2> /dev/null - "${LZIP}" < trunc.lz > out 2> /dev/null + "${LZIP}" < trunc.lz > /dev/null 2>&1 [ $? = 2 ] || test_failed $LINENO $i done else printf "\nwarning: skipping truncation test: 'dd' does not work on your system." fi -rm -f in2.lz in3.lz trunc.lz out || framework_failure +rm -f in2.lz in3.lz trunc.lz || framework_failure cat "${in_lz}" > ingin.lz || framework_failure printf "g" >> ingin.lz || framework_failure cat "${in_lz}" >> ingin.lz || framework_failure -"${LZIP}" < ingin.lz > copy || test_failed $LINENO +"${LZIP}" -d < ingin.lz > copy || test_failed $LINENO cmp "${in}" copy || test_failed $LINENO rm -f copy ingin.lz || framework_failure From d9ee6fc0c59a55389f103b9a43488204fa3b3217 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 15:08:42 +0100 Subject: [PATCH 09/10] Adding upstream version 1.4. Signed-off-by: Daniel Baumann --- ChangeLog | 9 ++++++-- INSTALL | 5 +++-- Makefile.in | 7 ++++-- NEWS | 7 +++--- README | 37 +++++-------------------------- configure | 19 ++++++++++------ lzd.cc | 55 ++++++++++++++++++++++++---------------------- testsuite/check.sh | 28 +++++++++++------------ 8 files changed, 79 insertions(+), 88 deletions(-) diff --git a/ChangeLog b/ChangeLog index 042b251..f417214 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2024-01-02 Antonio Diaz Diaz + + * Version 1.4 released. + * lzd.cc: Use header_size and trailer_size instead of 6 and 20. + 2022-10-24 Antonio Diaz Diaz * Version 1.3 released. @@ -6,7 +11,7 @@ 2021-01-04 Antonio Diaz Diaz * Version 1.2 released. - * lzd.cc (main): Verify also mismatches in member size. + * lzd.cc (main): Check also mismatches in member size. Accept and ignore the option '-d' for compatibility with zutils. Remove warning about "lzd not safe for real work". Print license notice. @@ -70,7 +75,7 @@ * Version 0.1 released. -Copyright (C) 2013-2022 Antonio Diaz Diaz. +Copyright (C) 2013-2024 Antonio Diaz Diaz. This file is a collection of facts, and thus it is not copyrightable, but just in case, you have unlimited permission to copy, distribute, and diff --git a/INSTALL b/INSTALL index ecf03f1..2c82368 100644 --- a/INSTALL +++ b/INSTALL @@ -31,7 +31,8 @@ extracted from the archive. 4. Optionally, type 'make check' to run the tests that come with lzd. 5. Type 'make install' to install the program and any data files and - documentation. + documentation. You need root privileges to install into a prefix owned + by root. Another way @@ -51,7 +52,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2022 Antonio Diaz Diaz. +Copyright (C) 2013-2024 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute, and modify it. diff --git a/Makefile.in b/Makefile.in index ced714d..120a41b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -24,15 +24,18 @@ $(progname) : $(objs) %.o : %.cc $(CXX) $(CPPFLAGS) $(CXXFLAGS) -DPROGVERSION=\"$(pkgversion)\" -c -o $@ $< -$(objs) : Makefile +# prevent 'make' from trying to remake source files +$(VPATH)/configure $(VPATH)/Makefile.in $(VPATH)/doc/$(pkgname).texi : ; +%.h %.cc : ; +$(objs) : Makefile doc : info : $(VPATH)/doc/$(pkgname).info $(VPATH)/doc/$(pkgname).info : $(VPATH)/doc/$(pkgname).texi - cd $(VPATH)/doc && makeinfo $(pkgname).texi + cd $(VPATH)/doc && $(MAKEINFO) $(pkgname).texi man : $(VPATH)/doc/$(progname).1 diff --git a/NEWS b/NEWS index 2416499..be2c30b 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,4 @@ -Changes in version 1.3: +Changes in version 1.4: -Lzd now discards the first byte of the LZMA stream explicity (instead of -shifting 1 extra byte in the initialization of 'code') to make the intent -clearer. +Define constants 'header_size' and 'trailer_size' instead of using 6 and 20. +(Lzd is supposed to be educational, and using numbers is bad practice). diff --git a/README b/README index fae23bc..03fb742 100644 --- a/README +++ b/README @@ -7,7 +7,7 @@ lzip works. Lzd is written in C++. The source code of lzd is used in the lzip manual as a reference decompressor in the description of the lzip file format. Reading the lzip manual will help you understand the source code. Lzd is compliant with the -lzip specification; it verifies the 3 integrity factors. +lzip specification; it checks the 3 integrity factors. The source code of lzd is also used as a reference in the description of the media type 'application/lzip'. @@ -18,33 +18,9 @@ ignores) the option '-d' for compatibility with other lzip tools. In particular, accepting the option '-d' allows lzd to be used as argument to the option '--lz' of the tools from the zutils package. -Lzd will correctly decompress the concatenation of two or more compressed +Lzd correctly decompresses the concatenation of two or more compressed files. The result is the concatenation of the corresponding decompressed -data. Integrity of such concatenated compressed input is also verified. - -The lzip file format is designed for data sharing and long-term archiving, -taking into account both data integrity and decoder availability: - - * The lzip format provides very safe integrity checking and some data - recovery means. The program lziprecover can repair bit flip errors - (one of the most common forms of data corruption) in lzip files, and - provides data recovery capabilities, including error-checked merging - of damaged copies of a file. - - * The lzip format is as simple as possible (but not simpler). The lzip - manual provides the source code of a simple decompressor along with a - detailed explanation of how it works, so that with the only help of the - lzip manual it would be possible for a digital archaeologist to extract - the data from a lzip file long after quantum computers eventually - render LZMA obsolete. - - * Additionally the lzip reference implementation is copylefted, which - guarantees that it will remain free forever. - -A nice feature of the lzip format is that a corrupt byte is easier to repair -the nearer it is from the beginning of the file. Therefore, with the help of -lziprecover, losing an entire archive just because of a corrupt byte near -the beginning is a thing of the past. +data. Integrity of such concatenated compressed input is also checked. The ideas embodied in lzd are due to (at least) the following people: Abraham Lempel and Jacob Ziv (for the LZ algorithm), Andrei Markov (for the @@ -52,11 +28,10 @@ definition of Markov chains), G.N.N. Martin (for the definition of range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2022 Antonio Diaz Diaz. +Copyright (C) 2013-2024 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute, and modify it. -The file Makefile.in is a data file used by configure to produce the -Makefile. It has the same copyright owner and permissions that configure -itself. +The file Makefile.in is a data file used by configure to produce the Makefile. +It has the same copyright owner and permissions that configure itself. diff --git a/configure b/configure index cf10b79..a84fda2 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2022 Antonio Diaz Diaz. +# Copyright (C) 2013-2024 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute, and modify it. pkgname=lzd -pkgversion=1.3 +pkgversion=1.4 progname=lzd srctrigger=lzd.cc @@ -24,6 +24,7 @@ CXX=g++ CPPFLAGS= CXXFLAGS='-Wall -W -O2' LDFLAGS= +MAKEINFO=makeinfo # checking whether we are using GNU C++. /bin/sh -c "${CXX} --version" > /dev/null 2>&1 || { CXX=c++ ; CXXFLAGS=-O2 ; } @@ -65,10 +66,11 @@ while [ $# != 0 ] ; do echo " --infodir=DIR info files directory [${infodir}]" echo " --mandir=DIR man pages directory [${mandir}]" echo " CXX=COMPILER C++ compiler to use [${CXX}]" - echo " CPPFLAGS=OPTIONS command line options for the preprocessor [${CPPFLAGS}]" - echo " CXXFLAGS=OPTIONS command line options for the C++ compiler [${CXXFLAGS}]" + echo " CPPFLAGS=OPTIONS command-line options for the preprocessor [${CPPFLAGS}]" + echo " CXXFLAGS=OPTIONS command-line options for the C++ compiler [${CXXFLAGS}]" echo " CXXFLAGS+=OPTIONS append options to the current value of CXXFLAGS" - echo " LDFLAGS=OPTIONS command line options for the linker [${LDFLAGS}]" + echo " LDFLAGS=OPTIONS command-line options for the linker [${LDFLAGS}]" + echo " MAKEINFO=NAME makeinfo program to use [${MAKEINFO}]" echo exit 0 ;; --version | -V) @@ -96,6 +98,7 @@ while [ $# != 0 ] ; do CXXFLAGS=*) CXXFLAGS=${optarg} ;; CXXFLAGS+=*) CXXFLAGS="${CXXFLAGS} ${optarg}" ;; LDFLAGS=*) LDFLAGS=${optarg} ;; + MAKEINFO=*) MAKEINFO=${optarg} ;; --*) echo "configure: WARNING: unrecognized option: '${option}'" 1>&2 ;; @@ -147,7 +150,7 @@ if [ -z "${no_create}" ] ; then # This script is free software: you have unlimited permission # to copy, distribute, and modify it. -exec /bin/sh $0 ${args} --no-create +exec /bin/sh "$0" ${args} --no-create EOF chmod +x config.status fi @@ -164,10 +167,11 @@ echo "CXX = ${CXX}" echo "CPPFLAGS = ${CPPFLAGS}" echo "CXXFLAGS = ${CXXFLAGS}" echo "LDFLAGS = ${LDFLAGS}" +echo "MAKEINFO = ${MAKEINFO}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2022 Antonio Diaz Diaz. +# Copyright (C) 2013-2024 Antonio Diaz Diaz. # This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission @@ -187,6 +191,7 @@ CXX = ${CXX} CPPFLAGS = ${CPPFLAGS} CXXFLAGS = ${CXXFLAGS} LDFLAGS = ${LDFLAGS} +MAKEINFO = ${MAKEINFO} EOF cat "${srcdir}/Makefile.in" >> Makefile diff --git a/lzd.cc b/lzd.cc index 9e1c3b8..3cf3f13 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2022 Antonio Diaz Diaz. + Copyright (C) 2013-2024 Antonio Diaz Diaz. This program is free software. Redistribution and use in source and binary forms, with or without modification, are permitted provided @@ -18,7 +18,7 @@ */ /* Exit status: 0 for a normal exit, 1 for environmental problems - (file not found, invalid command line options, I/O errors, etc), 2 to + (file not found, invalid command-line options, I/O errors, etc), 2 to indicate a corrupt or invalid input file. */ @@ -130,10 +130,11 @@ public: const CRC32 crc32; -typedef uint8_t Lzip_header[6]; // 0-3 magic bytes - // 4 version - // 5 coded dictionary size -typedef uint8_t Lzip_trailer[20]; +enum { header_size = 6, trailer_size = 20 }; +typedef uint8_t Lzip_header[header_size]; // 0-3 magic bytes + // 4 version + // 5 coded dictionary size +typedef uint8_t Lzip_trailer[trailer_size]; // 0-3 CRC32 of the uncompressed data // 4-11 size of the uncompressed data // 12-19 member size including header and trailer @@ -145,7 +146,8 @@ class Range_decoder uint32_t range; public: - Range_decoder() : member_pos( 6 ), code( 0 ), range( 0xFFFFFFFFU ) + Range_decoder() + : member_pos( header_size ), code( 0 ), range( 0xFFFFFFFFU ) { get_byte(); // discard first byte of the LZMA stream for( int i = 0; i < 4; ++i ) code = ( code << 8 ) | get_byte(); @@ -168,9 +170,9 @@ public: return symbol; } - unsigned decode_bit( Bit_model & bm ) + bool decode_bit( Bit_model & bm ) { - unsigned symbol; + bool symbol; const uint32_t bound = ( range >> bit_model_total_bits ) * bm.probability; if( code < bound ) { @@ -216,8 +218,8 @@ public: unsigned symbol = 1; for( int i = 7; i >= 0; --i ) { - const unsigned match_bit = ( match_byte >> i ) & 1; - const unsigned bit = decode_bit( bm[symbol+(match_bit<<8)+0x100] ); + const bool match_bit = ( match_byte >> i ) & 1; + const bool bit = decode_bit( bm[symbol+(match_bit<<8)+0x100] ); symbol = ( symbol << 1 ) | bit; if( match_bit != bit ) { @@ -232,11 +234,12 @@ public: unsigned decode_len( Len_model & lm, const int pos_state ) { if( decode_bit( lm.choice1 ) == 0 ) - return decode_tree( lm.bm_low[pos_state], len_low_bits ); + return min_match_len + + decode_tree( lm.bm_low[pos_state], len_low_bits ); if( decode_bit( lm.choice2 ) == 0 ) - return len_low_symbols + + return min_match_len + len_low_symbols + decode_tree( lm.bm_mid[pos_state], len_mid_bits ); - return len_low_symbols + len_mid_symbols + + return min_match_len + len_low_symbols + len_mid_symbols + decode_tree( lm.bm_high, len_high_bits ); } }; @@ -371,12 +374,12 @@ bool LZ_decoder::decode_member() // Return false if error rep0 = distance; } state.set_rep(); - len = min_match_len + rdec.decode_len( rep_len_model, pos_state ); + len = rdec.decode_len( rep_len_model, pos_state ); } else // match { rep3 = rep2; rep2 = rep1; rep1 = rep0; - len = min_match_len + rdec.decode_len( match_len_model, pos_state ); + len = rdec.decode_len( match_len_model, pos_state ); const int len_state = std::min( len - min_match_len, len_states - 1 ); rep0 = rdec.decode_tree( bm_dis_slot[len_state], dis_slot_bits ); if( rep0 >= start_dis_model ) @@ -395,7 +398,7 @@ bool LZ_decoder::decode_member() // Return false if error if( rep0 == 0xFFFFFFFFU ) // marker found { flush_data(); - return ( len == min_match_len ); // End Of Stream marker + return len == min_match_len; // End Of Stream marker } } } @@ -420,10 +423,10 @@ int main( const int argc, const char * const argv[] ) "See the lzip manual for an explanation of the code.\n" "\nUsage: %s [-d] < file.lz > file\n" "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2022 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2024 Antonio Diaz Diaz.\n" "License 2-clause BSD.\n" - "This is free software: you are free to change and redistribute it.\n" - "There is NO WARRANTY, to the extent permitted by law.\n" + "This is free software: you are free to change and redistribute " + "it.\nThere is NO WARRANTY, to the extent permitted by law.\n" "Report bugs to lzip-bug@nongnu.org\n" "Lzd home page: http://www.nongnu.org/lzip/lzd.html\n", PROGVERSION, argv[0] ); @@ -437,8 +440,8 @@ int main( const int argc, const char * const argv[] ) for( bool first_member = true; ; first_member = false ) { - Lzip_header header; // verify header - for( int i = 0; i < 6; ++i ) header[i] = std::getc( stdin ); + Lzip_header header; // check header + for( int i = 0; i < header_size; ++i ) header[i] = std::getc( stdin ); if( std::feof( stdin ) || std::memcmp( header, "LZIP\x01", 5 ) != 0 ) { if( first_member ) @@ -449,15 +452,15 @@ int main( const int argc, const char * const argv[] ) unsigned dict_size = 1 << ( header[5] & 0x1F ); dict_size -= ( dict_size / 16 ) * ( ( header[5] >> 5 ) & 7 ); if( dict_size < min_dictionary_size || dict_size > max_dictionary_size ) - { std::fputs( "Invalid dictionary size in member header.\n", stderr ); - return 2; } + { std::fputs( "Invalid dictionary size in member header.\n", + stderr ); return 2; } LZ_decoder decoder( dict_size ); // decode LZMA stream if( !decoder.decode_member() ) { std::fputs( "Data error\n", stderr ); return 2; } - Lzip_trailer trailer; // verify trailer - for( int i = 0; i < 20; ++i ) trailer[i] = decoder.get_byte(); + Lzip_trailer trailer; // check trailer + for( int i = 0; i < trailer_size; ++i ) trailer[i] = decoder.get_byte(); int retval = 0; unsigned crc = 0; for( int i = 3; i >= 0; --i ) crc = ( crc << 8 ) + trailer[i]; diff --git a/testsuite/check.sh b/testsuite/check.sh index 33ffb8a..b041fe8 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2022 Antonio Diaz Diaz. +# Copyright (C) 2013-2024 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute, and modify it. @@ -41,20 +41,20 @@ printf "testing lzd-%s..." "$2" [ $? = 2 ] || test_failed $LINENO for i in "${in_lz}" "${in_em}" ; do - "${LZIP}" < "$i" > copy || test_failed $LINENO "$i" - cmp "${in}" copy || test_failed $LINENO "$i" + "${LZIP}" < "$i" > out || test_failed $LINENO "$i" + cmp "${in}" out || test_failed $LINENO "$i" done cat "${in}" "${in}" > in2 || framework_failure -cat "${in_lz}" "${in_lz}" | "${LZIP}" > copy2 || test_failed $LINENO -cmp in2 copy2 || test_failed $LINENO -rm -f copy2 || framework_failure +cat "${in_lz}" "${in_lz}" | "${LZIP}" > out2 || test_failed $LINENO +cmp in2 out2 || test_failed $LINENO +rm -f out2 || framework_failure -cat "${in_lz}" "${in_lz}" > copy2.lz || framework_failure -printf "\ngarbage" >> copy2.lz || framework_failure -"${LZIP}" -d < copy2.lz > copy2 || test_failed $LINENO -cmp in2 copy2 || test_failed $LINENO -rm -f in2 copy2 copy2.lz || framework_failure +cat "${in_lz}" "${in_lz}" > out2.lz || framework_failure +printf "\ngarbage" >> out2.lz || framework_failure +"${LZIP}" -d < out2.lz > out2 || test_failed $LINENO +cmp in2 out2 || test_failed $LINENO +rm -f in2 out2 out2.lz || framework_failure printf "\ntesting bad input..." @@ -90,9 +90,9 @@ rm -f in2.lz in3.lz trunc.lz || framework_failure cat "${in_lz}" > ingin.lz || framework_failure printf "g" >> ingin.lz || framework_failure cat "${in_lz}" >> ingin.lz || framework_failure -"${LZIP}" -d < ingin.lz > copy || test_failed $LINENO -cmp "${in}" copy || test_failed $LINENO -rm -f copy ingin.lz || framework_failure +"${LZIP}" -d < ingin.lz > out || test_failed $LINENO +cmp "${in}" out || test_failed $LINENO +rm -f out ingin.lz || framework_failure echo if [ ${fail} = 0 ] ; then From 9a45d2df811b4b214656c31b0dca10cc4316d1af Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Thu, 20 Feb 2025 15:09:22 +0100 Subject: [PATCH 10/10] Adding upstream version 1.5. Signed-off-by: Daniel Baumann --- ChangeLog | 16 +++++++++------ INSTALL | 5 +++-- Makefile.in | 12 +++++------ NEWS | 9 +++++--- README | 4 +++- configure | 8 ++++---- lzd.cc | 22 ++++++++++++-------- testsuite/check.sh | 43 +++++++++++++++++++++++++++------------ testsuite/em.lz | Bin 0 -> 36 bytes testsuite/fox_bm.lz | Bin 80 -> 0 bytes testsuite/fox_nz.lz | Bin 0 -> 80 bytes testsuite/test.txt | 6 ++---- testsuite/test.txt.lz | Bin 7376 -> 7341 bytes testsuite/test_em.txt.lz | Bin 14024 -> 0 bytes 14 files changed, 77 insertions(+), 48 deletions(-) create mode 100644 testsuite/em.lz delete mode 100644 testsuite/fox_bm.lz create mode 100644 testsuite/fox_nz.lz delete mode 100644 testsuite/test_em.txt.lz diff --git a/ChangeLog b/ChangeLog index f417214..bbed3c1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2025-01-02 Antonio Diaz Diaz + + * Version 1.5 released. + * lzd.cc: Reject empty members and nonzero first LZMA byte. + 2024-01-02 Antonio Diaz Diaz * Version 1.4 released. @@ -6,7 +11,7 @@ 2022-10-24 Antonio Diaz Diaz * Version 1.3 released. - * lzd.cc (Range_decoder): Discard first byte explicitly. + * lzd.cc (Range_decoder): Discard first LZMA byte explicitly. 2021-01-04 Antonio Diaz Diaz @@ -28,7 +33,7 @@ * Version 1.0 released. * lzd.cc: Minor code improvements. - * check.sh: A POSIX shell is required to run the tests. + * check.sh: Require a POSIX shell. 2016-05-10 Antonio Diaz Diaz @@ -75,8 +80,7 @@ * Version 0.1 released. -Copyright (C) 2013-2024 Antonio Diaz Diaz. +Copyright (C) 2013-2025 Antonio Diaz Diaz. -This file is a collection of facts, and thus it is not copyrightable, -but just in case, you have unlimited permission to copy, distribute, and -modify it. +This file is a collection of facts, and thus it is not copyrightable, but just +in case, you have unlimited permission to copy, distribute, and modify it. diff --git a/INSTALL b/INSTALL index 2c82368..97a4fa6 100644 --- a/INSTALL +++ b/INSTALL @@ -4,7 +4,8 @@ You will need a C++98 compiler with support for 'long long'. (gcc 3.3.6 or newer is recommended). I use gcc 6.1.0 and 3.3.6, but the code should compile with any standards compliant compiler. -Gcc is available at http://gcc.gnu.org. +Gcc is available at http://gcc.gnu.org +Lzip is available at http://www.nongnu.org/lzip/lzip.html Procedure @@ -52,7 +53,7 @@ After running 'configure', you can run 'make' and 'make install' as explained above. -Copyright (C) 2013-2024 Antonio Diaz Diaz. +Copyright (C) 2013-2025 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute, and modify it. diff --git a/Makefile.in b/Makefile.in index 120a41b..47358f5 100644 --- a/Makefile.in +++ b/Makefile.in @@ -2,8 +2,8 @@ DISTNAME = $(pkgname)-$(pkgversion) INSTALL = install INSTALL_PROGRAM = $(INSTALL) -m 755 -INSTALL_DATA = $(INSTALL) -m 644 INSTALL_DIR = $(INSTALL) -d -m 755 +INSTALL_DATA = $(INSTALL) -m 644 SHELL = /bin/sh CAN_RUN_INSTALLINFO = $(SHELL) -c "install-info --version" > /dev/null 2>&1 @@ -26,7 +26,8 @@ $(progname) : $(objs) # prevent 'make' from trying to remake source files $(VPATH)/configure $(VPATH)/Makefile.in $(VPATH)/doc/$(pkgname).texi : ; -%.h %.cc : ; +MAKEFLAGS += -r +.SUFFIXES : $(objs) : Makefile @@ -40,8 +41,7 @@ $(VPATH)/doc/$(pkgname).info : $(VPATH)/doc/$(pkgname).texi man : $(VPATH)/doc/$(progname).1 $(VPATH)/doc/$(progname).1 : $(progname) - help2man -n 'educational decompressor for the lzip format' \ - -o $@ --no-info ./$(progname) + help2man -n 'educational decompressor for the lzip format' -o $@ --no-info ./$(progname) Makefile : $(VPATH)/configure $(VPATH)/Makefile.in ./config.status @@ -108,10 +108,10 @@ dist : doc $(DISTNAME)/*.cc \ $(DISTNAME)/testsuite/check.sh \ $(DISTNAME)/testsuite/test.txt \ + $(DISTNAME)/testsuite/em.lz \ $(DISTNAME)/testsuite/fox.lz \ $(DISTNAME)/testsuite/fox_*.lz \ - $(DISTNAME)/testsuite/test.txt.lz \ - $(DISTNAME)/testsuite/test_em.txt.lz + $(DISTNAME)/testsuite/test.txt.lz rm -f $(DISTNAME) lzip -v -9 $(DISTNAME).tar diff --git a/NEWS b/NEWS index be2c30b..370140c 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,7 @@ -Changes in version 1.4: +Changes in version 1.5: -Define constants 'header_size' and 'trailer_size' instead of using 6 and 20. -(Lzd is supposed to be educational, and using numbers is bad practice). +lzd now exits with error status 2 if any empty member is found in a +multimember file. + +lzd now exits with error status 2 if the first byte of the LZMA stream is +not 0. diff --git a/README b/README index 03fb742..1dff5ae 100644 --- a/README +++ b/README @@ -1,3 +1,5 @@ +See the file INSTALL for compilation and installation instructions. + Description Lzd is a simplified decompressor for the lzip format with an educational @@ -28,7 +30,7 @@ definition of Markov chains), G.N.N. Martin (for the definition of range encoding), and Igor Pavlov (for putting all the above together in LZMA). -Copyright (C) 2013-2024 Antonio Diaz Diaz. +Copyright (C) 2013-2025 Antonio Diaz Diaz. This file is free documentation: you have unlimited permission to copy, distribute, and modify it. diff --git a/configure b/configure index a84fda2..0345a3f 100755 --- a/configure +++ b/configure @@ -1,12 +1,12 @@ #! /bin/sh # configure script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2024 Antonio Diaz Diaz. +# Copyright (C) 2013-2025 Antonio Diaz Diaz. # # This configure script is free software: you have unlimited permission # to copy, distribute, and modify it. pkgname=lzd -pkgversion=1.4 +pkgversion=1.5 progname=lzd srctrigger=lzd.cc @@ -109,7 +109,7 @@ while [ $# != 0 ] ; do exit 1 ;; esac - # Check if the option took a separate argument + # Check whether the option took a separate argument if [ "${arg2}" = yes ] ; then if [ $# != 0 ] ; then args="${args} \"$1\"" ; shift else echo "configure: Missing argument to '${option}'" 1>&2 @@ -171,7 +171,7 @@ echo "MAKEINFO = ${MAKEINFO}" rm -f Makefile cat > Makefile << EOF # Makefile for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2024 Antonio Diaz Diaz. +# Copyright (C) 2013-2025 Antonio Diaz Diaz. # This file was generated automatically by configure. Don't edit. # # This Makefile is free software: you have unlimited permission diff --git a/lzd.cc b/lzd.cc index 3cf3f13..4d9e40b 100644 --- a/lzd.cc +++ b/lzd.cc @@ -1,5 +1,5 @@ /* Lzd - Educational decompressor for the lzip format - Copyright (C) 2013-2024 Antonio Diaz Diaz. + Copyright (C) 2013-2025 Antonio Diaz Diaz. This program is free software. Redistribution and use in source and binary forms, with or without modification, are permitted provided @@ -149,7 +149,8 @@ public: Range_decoder() : member_pos( header_size ), code( 0 ), range( 0xFFFFFFFFU ) { - get_byte(); // discard first byte of the LZMA stream + if( get_byte() != 0 ) // check first LZMA byte + { std::fputs( "Nonzero first LZMA byte.\n", stderr ); std::exit( 2 ); } for( int i = 0; i < 4; ++i ) code = ( code << 8 ) | get_byte(); } @@ -392,8 +393,7 @@ bool LZ_decoder::decode_member() // Return false if error direct_bits ); else { - rep0 += - rdec.decode( direct_bits - dis_align_bits ) << dis_align_bits; + rep0 += rdec.decode( direct_bits-dis_align_bits ) << dis_align_bits; rep0 += rdec.decode_tree_reversed( bm_align, dis_align_bits ); if( rep0 == 0xFFFFFFFFU ) // marker found { @@ -423,7 +423,7 @@ int main( const int argc, const char * const argv[] ) "See the lzip manual for an explanation of the code.\n" "\nUsage: %s [-d] < file.lz > file\n" "Lzd decompresses from standard input to standard output.\n" - "\nCopyright (C) 2024 Antonio Diaz Diaz.\n" + "\nCopyright (C) 2025 Antonio Diaz Diaz.\n" "License 2-clause BSD.\n" "This is free software: you are free to change and redistribute " "it.\nThere is NO WARRANTY, to the extent permitted by law.\n" @@ -438,6 +438,7 @@ int main( const int argc, const char * const argv[] ) setmode( STDOUT_FILENO, O_BINARY ); #endif + bool empty = false, multi = false; for( bool first_member = true; ; first_member = false ) { Lzip_header header; // check header @@ -457,7 +458,7 @@ int main( const int argc, const char * const argv[] ) LZ_decoder decoder( dict_size ); // decode LZMA stream if( !decoder.decode_member() ) - { std::fputs( "Data error\n", stderr ); return 2; } + { std::fputs( "Data error.\n", stderr ); return 2; } Lzip_trailer trailer; // check trailer for( int i = 0; i < trailer_size; ++i ) trailer[i] = decoder.get_byte(); @@ -465,24 +466,27 @@ int main( const int argc, const char * const argv[] ) unsigned crc = 0; for( int i = 3; i >= 0; --i ) crc = ( crc << 8 ) + trailer[i]; if( crc != decoder.crc() ) - { std::fputs( "CRC mismatch\n", stderr ); retval = 2; } + { std::fputs( "CRC mismatch.\n", stderr ); retval = 2; } unsigned long long data_size = 0; for( int i = 11; i >= 4; --i ) data_size = ( data_size << 8 ) + trailer[i]; if( data_size != decoder.data_position() ) - { std::fputs( "Data size mismatch\n", stderr ); retval = 2; } + { std::fputs( "Data size mismatch.\n", stderr ); retval = 2; } + multi = !first_member; if( data_size == 0 ) empty = true; unsigned long long member_size = 0; for( int i = 19; i >= 12; --i ) member_size = ( member_size << 8 ) + trailer[i]; if( member_size != decoder.member_position() ) - { std::fputs( "Member size mismatch\n", stderr ); retval = 2; } + { std::fputs( "Member size mismatch.\n", stderr ); retval = 2; } if( retval ) return retval; } if( std::fclose( stdout ) != 0 ) { std::fprintf( stderr, "Error closing stdout: %s\n", std::strerror( errno ) ); return 1; } + if( empty && multi ) + { std::fputs( "Empty member not allowed.\n", stderr ); return 2; } return 0; } diff --git a/testsuite/check.sh b/testsuite/check.sh index b041fe8..9fb3925 100755 --- a/testsuite/check.sh +++ b/testsuite/check.sh @@ -1,6 +1,6 @@ #! /bin/sh # check script for Lzd - Educational decompressor for the lzip format -# Copyright (C) 2013-2024 Antonio Diaz Diaz. +# Copyright (C) 2013-2025 Antonio Diaz Diaz. # # This script is free software: you have unlimited permission # to copy, distribute, and modify it. @@ -30,8 +30,9 @@ cd "${objdir}"/tmp || framework_failure in="${testdir}"/test.txt in_lz="${testdir}"/test.txt.lz -in_em="${testdir}"/test_em.txt.lz +em_lz="${testdir}"/em.lz fox_lz="${testdir}"/fox.lz +fnz_lz="${testdir}"/fox_nz.lz fail=0 test_failed() { fail=1 ; printf " $1" ; [ -z "$2" ] || printf "($2)" ; } @@ -40,10 +41,8 @@ printf "testing lzd-%s..." "$2" "${LZIP}" < "${in}" 2> /dev/null [ $? = 2 ] || test_failed $LINENO -for i in "${in_lz}" "${in_em}" ; do - "${LZIP}" < "$i" > out || test_failed $LINENO "$i" - cmp "${in}" out || test_failed $LINENO "$i" -done +"${LZIP}" < "${in_lz}" > out || test_failed $LINENO +cmp "${in}" out || test_failed $LINENO cat "${in}" "${in}" > in2 || framework_failure cat "${in_lz}" "${in_lz}" | "${LZIP}" > out2 || test_failed $LINENO @@ -56,9 +55,27 @@ printf "\ngarbage" >> out2.lz || framework_failure cmp in2 out2 || test_failed $LINENO rm -f in2 out2 out2.lz || framework_failure +touch empty || framework_failure +"${LZIP}" -d < "${em_lz}" > em || test_failed $LINENO +cmp empty em || test_failed $LINENO + printf "\ntesting bad input..." -for i in fox_bm.lz fox_v2.lz fox_s11.lz fox_de20.lz \ +cat "${em_lz}" "${em_lz}" | "${LZIP}" -d > em 2> /dev/null +[ $? = 2 ] || test_failed $LINENO +cmp empty em || test_failed $LINENO +rm -f empty em || framework_failure +cat "${em_lz}" "${in_lz}" | "${LZIP}" -d > out 2> /dev/null +[ $? = 2 ] || test_failed $LINENO +cmp "${in}" out || test_failed $LINENO +cat "${in_lz}" "${em_lz}" | "${LZIP}" -d > out 2> /dev/null +[ $? = 2 ] || test_failed $LINENO +cmp "${in}" out || test_failed $LINENO + +"${LZIP}" < "${fnz_lz}" 2> /dev/null +[ $? = 2 ] || test_failed $LINENO + +for i in fox_v2.lz fox_s11.lz fox_de20.lz \ fox_bcrc.lz fox_crc0.lz fox_das46.lz fox_mes81.lz ; do "${LZIP}" < "${testdir}"/$i > /dev/null 2>&1 [ $? = 2 ] || test_failed $LINENO $i @@ -70,24 +87,24 @@ for i in fox_bcrc.lz fox_crc0.lz fox_das46.lz fox_mes81.lz ; do [ $? = 2 ] || test_failed $LINENO $i cmp fox out || test_failed $LINENO $i done -rm -f fox out || framework_failure +rm -f fox || framework_failure cat "${in_lz}" "${in_lz}" > in2.lz || framework_failure cat "${in_lz}" "${in_lz}" "${in_lz}" > in3.lz || framework_failure -if dd if=in3.lz of=trunc.lz bs=14752 count=1 2> /dev/null && - [ -e trunc.lz ] && cmp in2.lz trunc.lz > /dev/null 2>&1 ; then +if dd if=in3.lz of=trunc.lz bs=14682 count=1 2> /dev/null && + [ -e trunc.lz ] && cmp in2.lz trunc.lz ; then # can't detect truncated header of non-first member - for i in 6 20 14734 14758 ; do + for i in 6 20 14664 14688 ; do dd if=in3.lz of=trunc.lz bs=$i count=1 2> /dev/null "${LZIP}" < trunc.lz > /dev/null 2>&1 [ $? = 2 ] || test_failed $LINENO $i done else - printf "\nwarning: skipping truncation test: 'dd' does not work on your system." + printf "warning: skipping truncation test: 'dd' does not work on your system." fi rm -f in2.lz in3.lz trunc.lz || framework_failure -cat "${in_lz}" > ingin.lz || framework_failure +cp "${in_lz}" ingin.lz || framework_failure printf "g" >> ingin.lz || framework_failure cat "${in_lz}" >> ingin.lz || framework_failure "${LZIP}" -d < ingin.lz > out || test_failed $LINENO diff --git a/testsuite/em.lz b/testsuite/em.lz new file mode 100644 index 0000000000000000000000000000000000000000..ec607250eb85b946c420050d70e7514ca2b565f6 GIT binary patch literal 36 acmeZ?@(f_)VQBvU`~Uv~45&Z_$^`(o*#@it literal 0 HcmV?d00001 diff --git a/testsuite/fox_bm.lz b/testsuite/fox_bm.lz deleted file mode 100644 index d71914fc3f364f84cfce1138cdd6c636ef309ea3..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 80 zcmeZ?$_!xSVbGG|Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E08NY^3IG5A diff --git a/testsuite/fox_nz.lz b/testsuite/fox_nz.lz new file mode 100644 index 0000000000000000000000000000000000000000..44a4b58b881d207627f6081d8ad04708c25400dc GIT binary patch literal 80 zcmeZ?@(f_)Nz{_!Sj4QF_R+iI=pxqtde3fNQjl6}^5c>03rDkGci1v_+dL64QRjTU cIqmVA>95u)|NqywfFbKlz-wIw2nc}E0AJQ0O8@`> literal 0 HcmV?d00001 diff --git a/testsuite/test.txt b/testsuite/test.txt index 9196a3a..423f0c0 100644 --- a/testsuite/test.txt +++ b/testsuite/test.txt @@ -1,8 +1,7 @@ GNU GENERAL PUBLIC LICENSE Version 2, June 1991 - Copyright (C) 1989, 1991 Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Copyright (C) 1989, 1991 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. @@ -339,8 +338,7 @@ Public License instead of this License. GNU GENERAL PUBLIC LICENSE Version 2, June 1991 - Copyright (C) 1989, 1991 Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Copyright (C) 1989, 1991 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. diff --git a/testsuite/test.txt.lz b/testsuite/test.txt.lz index 22cea6e4d2a58b4dcb006541dcdb8defabba0cbb..5dc169f7fb6e952f17e7a21ce3691eeaac2fb3aa 100644 GIT binary patch delta 7294 zcmV-^9D(D|IjuR6Zhys3yJ(c8peBW%f-elXuLG8+YcW?HC;m#{D%pU^WiRDBah9%H zoNKDm$X*ivN}frZPJV^dtsX$0%Z^SSxrOZEO@c$q7owY! z`W;W~c7VLKKJvfUJ)mGF=tyS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Z3j0Iws7&dV?49;?9&f#Q+`{WmMZIx^s`Z~1 zhD%E<3Ktq>(!vQxNG*1Mi+_n47)cvBtRaJu>9`jJmAmHeQ-h+Yt(`)8f8ZSl43ZE_ zMuh}Ovw~%FUQUe_EqaoQQ-dOBAZx9)bNN^g`Zn98i73zQOm*-0)!D(~aNucUL7ZR1O=417AbSGU>F`Q0L4}z5jH`T_ zC){OaNR`|Sm{3)>?A2&y)oweSnE?O*q6YGRO&Sh zDqvFo`?mO<mK0XU3GqvYCg?)6Gzve}e_^e&1cC1-m8Eef=CcV2A!kMTy=yc*ARHr}| zbW710YcfXCB%GE|^Te^WKzaOB7BwM0Fxq;TKczZjv3zxLb=qXFCMc(&bjB zQ`?vrFjn`de*fEvQC!%>Poj|kvui6=KoBvW@x$<5^YFwY>!p({O~Sk$ljIL_Mrz5o zWTMX$#v7?yb>33D%%$~kmAKc#PYJM|JbO_jS>8!Cuzv+*Bddb0V;^K8K^}5-ER?Ah zB-WZ5H_Cv6JT=YWQHw6H@$%R1V6`}4Y1SjL0D31AKJ5M@hvU-1yn!#~CNIMRrg<1; zbZaZDsy^qCKrs@G+2>+$f`LLRSv*cahZYQrdg6K1^#cgSrb`W}A=w$I3snNYhVI|6 z=C^AVd4F)m=+nn8tvbLg(L!kOC5RjDS^0`r)^bkkba2wa`CMSs1 z6pJ4{29|(EyCk&emj~UpEqWe;w^-tz3G@;yuQM8Mhxa`6tvD#wmAklWHISI|OQ$wj z!K_O4X`3NK;oh-Tm?Z^Mk#EAp#QXv2do!dCKN~jC4*h_EAyf{Nq9l$0000000MHx& I000000MqzJBme*a diff --git a/testsuite/test_em.txt.lz b/testsuite/test_em.txt.lz deleted file mode 100644 index 7e96250d9ec70bc7d8cb173f438c76be447e6b6f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 14024 zcmb7~Ly#~4lVsbrZQHhO+qP}nwr$(CZQJht_TQb^!`^1=Qc)3g%8I(YOc^an1wa^p z;D6u${tW>9zeV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