This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Zlib upgrade to v1.2.2


Hi,

This patch upgrades the zlib package to version 1.2.2.

Version 1.2.2 fixes a potential security vulnerability. From the
change log:

# Eliminate a potential security vulnerability when decoding invalid
  compressed data
# Fix bug when decompressing dynamic blocks with no distance codes
# Do not return an error when using gzread() on an empty file

Index: packages/services/compress/zlib/current/ChangeLog
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/ChangeLog,v
retrieving revision 1.13
diff -u -r1.13 ChangeLog
--- packages/services/compress/zlib/current/ChangeLog	27 Mar 2005 17:21:53 -0000	1.13
+++ packages/services/compress/zlib/current/ChangeLog	28 Jun 2005 15:43:26 -0000
@@ -1,3 +1,24 @@
+2005-06-28  Peter Korsgaard  <jacmet@sunsite.dk>
+
+	* src/ChangeLog: 
+	* src/configure: 
+	* src/deflate.c: 
+	* src/deflate.h: 
+	* src/FAQ: 
+	* src/gzio.c: 
+	* src/INDEX: 
+	* src/infback.c: 
+	* src/inffast.c: 
+	* src/inflate.c: 
+	* src/Makefile: 
+	* src/Makefile.in: 
+	* src/README: 
+	* src/trees.c: 
+	* src/zlib.3: 
+	* src/zutil.h: 
+	* include/zlib.h: 
+	* include/zconf.h: Upgrade to zlib-1.2.2
+
 2005-03-27  Andrew Lunn  <andrew.lunn@ascom.ch>
 
 	* tests/zlib1.c: Include diag.h for diag_printf proto.
Index: packages/services/compress/zlib/current/include/zconf.h
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/include/zconf.h,v
retrieving revision 1.6
diff -u -r1.6 zconf.h
--- packages/services/compress/zlib/current/include/zconf.h	25 May 2004 13:30:08 -0000	1.6
+++ packages/services/compress/zlib/current/include/zconf.h	28 Jun 2005 15:43:26 -0000
@@ -1,5 +1,5 @@
 /* zconf.h -- configuration of the zlib compression library
- * Copyright (C) 1995-2003 Jean-loup Gailly.
+ * Copyright (C) 1995-2004 Jean-loup Gailly.
  * For conditions of distribution and use, see copyright notice in zlib.h
  */
 
@@ -30,43 +30,46 @@
  * compile with -DZ_PREFIX. The "standard" zlib should be compiled without it.
  */
 #ifdef Z_PREFIX
-#  define deflateInit_  z_deflateInit_
-#  define deflate       z_deflate
-#  define deflateEnd    z_deflateEnd
-#  define inflateInit_  z_inflateInit_
-#  define inflate       z_inflate
-#  define inflateEnd    z_inflateEnd
-#  define deflateInit2_ z_deflateInit2_
-#  define deflateSetDictionary z_deflateSetDictionary
-#  define deflateCopy   z_deflateCopy
-#  define deflateReset  z_deflateReset
-#  define deflatePrime  z_deflatePrime
-#  define deflateParams z_deflateParams
-#  define deflateBound  z_deflateBound
-#  define inflateInit2_ z_inflateInit2_
-#  define inflateSetDictionary z_inflateSetDictionary
-#  define inflateSync   z_inflateSync
-#  define inflateSyncPoint z_inflateSyncPoint
-#  define inflateCopy   z_inflateCopy
-#  define inflateReset  z_inflateReset
-#  define compress      z_compress
-#  define compress2     z_compress2
-#  define compressBound z_compressBound
-#  define uncompress    z_uncompress
-#  define adler32       z_adler32
-#  define crc32         z_crc32
-#  define get_crc_table z_get_crc_table
-
-#  define Byte          z_Byte
-#  define uInt          z_uInt
-#  define uLong         z_uLong
-#  define Bytef         z_Bytef
-#  define charf         z_charf
-#  define intf          z_intf
-#  define uIntf         z_uIntf
-#  define uLongf        z_uLongf
-#  define voidpf        z_voidpf
-#  define voidp         z_voidp
+#  define deflateInit_          z_deflateInit_
+#  define deflate               z_deflate
+#  define deflateEnd            z_deflateEnd
+#  define inflateInit_          z_inflateInit_
+#  define inflate               z_inflate
+#  define inflateEnd            z_inflateEnd
+#  define deflateInit2_         z_deflateInit2_
+#  define deflateSetDictionary  z_deflateSetDictionary
+#  define deflateCopy           z_deflateCopy
+#  define deflateReset          z_deflateReset
+#  define deflateParams         z_deflateParams
+#  define deflateBound          z_deflateBound
+#  define deflatePrime          z_deflatePrime
+#  define inflateInit2_         z_inflateInit2_
+#  define inflateSetDictionary  z_inflateSetDictionary
+#  define inflateSync           z_inflateSync
+#  define inflateSyncPoint      z_inflateSyncPoint
+#  define inflateCopy           z_inflateCopy
+#  define inflateReset          z_inflateReset
+#  define inflateBack           z_inflateBack
+#  define inflateBackEnd        z_inflateBackEnd
+#  define compress              z_compress
+#  define compress2             z_compress2
+#  define compressBound         z_compressBound
+#  define uncompress            z_uncompress
+#  define adler32               z_adler32
+#  define crc32                 z_crc32
+#  define get_crc_table         z_get_crc_table
+#  define zError                z_zError
+
+#  define Byte                  z_Byte
+#  define uInt                  z_uInt
+#  define uLong                 z_uLong
+#  define Bytef                 z_Bytef
+#  define charf                 z_charf
+#  define intf                  z_intf
+#  define uIntf                 z_uIntf
+#  define uLongf                z_uLongf
+#  define voidpf                z_voidpf
+#  define voidp                 z_voidp
 #endif
 
 #if defined(__MSDOS__) && !defined(MSDOS)
@@ -298,7 +301,7 @@
 #  ifdef VMS
 #    include <unixio.h>   /* for off_t */
 #  endif
-#  define z_off_t  off_t
+#  define z_off_t off_t
 #endif
 #ifndef SEEK_SET
 #  define SEEK_SET        0       /* Seek from beginning of file.  */
@@ -306,11 +309,11 @@
 #  define SEEK_END        2       /* Set file pointer to EOF plus "offset" */
 #endif
 #ifndef z_off_t
-#  define  z_off_t long
+#  define z_off_t long
 #endif
 
 #if defined(__OS400__)
-#define NO_vsnprintf
+#  define NO_vsnprintf
 #endif
 
 #if defined(__MVS__)
Index: packages/services/compress/zlib/current/include/zlib.h
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/include/zlib.h,v
retrieving revision 1.4
diff -u -r1.4 zlib.h
--- packages/services/compress/zlib/current/include/zlib.h	24 May 2004 19:33:35 -0000	1.4
+++ packages/services/compress/zlib/current/include/zlib.h	28 Jun 2005 15:43:26 -0000
@@ -1,7 +1,7 @@
 /* zlib.h -- interface of the 'zlib' general purpose compression library
-  version 1.2.1, November 17th, 2003
+  version 1.2.2, October 3rd, 2004
 
-  Copyright (C) 1995-2003 Jean-loup Gailly and Mark Adler
+  Copyright (C) 1995-2004 Jean-loup Gailly and Mark Adler
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
@@ -37,8 +37,8 @@
 extern "C" {
 #endif
 
-#define ZLIB_VERSION "1.2.1"
-#define ZLIB_VERNUM 0x1210
+#define ZLIB_VERSION "1.2.2"
+#define ZLIB_VERNUM 0x1220
 
 /*
      The 'zlib' compression library provides in-memory compression and
@@ -53,24 +53,22 @@
   application must provide more input and/or consume the output
   (providing more output space) before each call.
 
-     The compressed data format used by the in-memory functions is the zlib
-  format, which is a zlib wrapper documented in RFC 1950, wrapped around a
-  deflate stream, which is itself documented in RFC 1951.
+     The compressed data format used by default by the in-memory functions is
+  the zlib format, which is a zlib wrapper documented in RFC 1950, wrapped
+  around a deflate stream, which is itself documented in RFC 1951.
 
      The library also supports reading and writing files in gzip (.gz) format
   with an interface similar to that of stdio using the functions that start
   with "gz".  The gzip format is different from the zlib format.  gzip is a
   gzip wrapper, documented in RFC 1952, wrapped around a deflate stream.
 
+     This library can optionally read and write gzip streams in memory as well.
+
      The zlib format was designed to be compact and fast for use in memory
   and on communications channels.  The gzip format was designed for single-
   file compression on file systems, has a larger header than zlib to maintain
   directory information, and uses a different, slower check method than zlib.
 
-     This library does not provide any functions to write gzip files in memory.
-  However such functions could be easily written using zlib's deflate function,
-  the documentation in the gzip RFC, and the examples in gzio.c.
-
      The library does not install any signal handler. The decoder checks
   the consistency of the compressed data, so the library should never
   crash even in case of corrupted input.
@@ -401,7 +399,7 @@
   because Z_BLOCK is used.
 
      If a preset dictionary is needed after this call (see inflateSetDictionary
-  below), inflate sets strm-adler to the adler32 checksum of the dictionary
+  below), inflate sets strm->adler to the adler32 checksum of the dictionary
   chosen by the compressor and returns Z_NEED_DICT; otherwise it sets
   strm->adler to the adler32 checksum of all output produced so far (that is,
   total_out bytes) and returns Z_OK, Z_STREAM_END or an error code as described
@@ -478,7 +476,8 @@
    16 to windowBits to write a simple gzip header and trailer around the
    compressed data instead of a zlib wrapper. The gzip header will have no
    file name, no extra data, no comment, no modification time (set to zero),
-   no header crc, and the operating system will be set to 255 (unknown).
+   no header crc, and the operating system will be set to 255 (unknown).  If a
+   gzip stream is being written, strm->adler is a crc32 instead of an adler32.
 
      The memLevel parameter specifies how much memory should be allocated
    for the internal compression state. memLevel=1 uses minimum memory but
@@ -649,7 +648,8 @@
      windowBits can also be greater than 15 for optional gzip decoding. Add
    32 to windowBits to enable zlib and gzip decoding with automatic header
    detection, or add 16 to decode only the gzip format (the zlib format will
-   return a Z_DATA_ERROR).
+   return a Z_DATA_ERROR.  If a gzip stream is being decoded, strm->adler is
+   a crc32 instead of an adler32.
 
      inflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough
    memory, Z_STREAM_ERROR if a parameter is invalid (such as a negative
@@ -1190,7 +1190,7 @@
     struct internal_state {int dummy;}; /* hack for buggy compilers */
 #endif
 
-ZEXTERN const char   * ZEXPORT zError           OF((int err));
+ZEXTERN const char   * ZEXPORT zError           OF((int));
 ZEXTERN int            ZEXPORT inflateSyncPoint OF((z_streamp z));
 ZEXTERN const uLongf * ZEXPORT get_crc_table    OF((void));
 
Index: packages/services/compress/zlib/current/src/ChangeLog
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/ChangeLog,v
retrieving revision 1.3
diff -u -r1.3 ChangeLog
--- packages/services/compress/zlib/current/src/ChangeLog	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/ChangeLog	28 Jun 2005 15:43:27 -0000
@@ -1,5 +1,47 @@
                 ChangeLog file for zlib
 
+Changes in 1.2.2 (3 October 2004)
+- Update zlib.h comments on gzip in-memory processing
+- Set adler to 1 in inflateReset() to support Java test suite [Walles]
+- Add contrib/dotzlib [Ravn]
+- Update win32/DLL_FAQ.txt [Truta]
+- Update contrib/minizip [Vollant]
+- Move contrib/visual-basic.txt to old/ [Truta]
+- Fix assembler builds in projects/visualc6/ [Truta]
+
+Changes in 1.2.1.2 (9 September 2004)
+- Update INDEX file
+- Fix trees.c to update strm->data_type (no one ever noticed!)
+- Fix bug in error case in inflate.c, infback.c, and infback9.c [Brown]
+- Add "volatile" to crc table flag declaration (for DYNAMIC_CRC_TABLE)
+- Add limited multitasking protection to DYNAMIC_CRC_TABLE
+- Add NO_vsnprintf for VMS in zutil.h [Mozilla]
+- Don't declare strerror() under VMS [Mozilla]
+- Add comment to DYNAMIC_CRC_TABLE to use get_crc_table() to initialize
+- Update contrib/ada [Anisimkov]
+- Update contrib/minizip [Vollant]
+- Fix configure to not hardcode directories for Darwin [Peterson]
+- Fix gzio.c to not return error on empty files [Brown]
+- Fix indentation; update version in contrib/delphi/ZLib.pas and
+  contrib/pascal/zlibpas.pas [Truta]
+- Update mkasm.bat in contrib/masmx86 [Truta]
+- Update contrib/untgz [Truta]
+- Add projects/README.projects [Truta]
+- Add project for MS Visual C++ 6.0 in projects/visualc6 [Cadieux, Truta]
+- Update win32/DLL_FAQ.txt [Truta]
+- Update list of Z_PREFIX symbols in zconf.h [Randers-Pehrson, Truta]
+- Remove an unnecessary assignment to curr in inftrees.c [Truta]
+- Add OS/2 to exe builds in configure [Poltorak]
+- Remove err dummy parameter in zlib.h [Kientzle]
+
+Changes in 1.2.1.1 (9 January 2004)
+- Update email address in README
+- Several FAQ updates
+- Fix a big fat bug in inftrees.c that prevented decoding valid
+  dynamic blocks with only literals and no distance codes --
+  Thanks to "Hot Emu" for the bug report and sample file
+- Add a note to puff.c on no distance codes case.
+
 Changes in 1.2.1 (17 November 2003)
 - Remove a tab in contrib/gzappend/gzappend.c
 - Update some interfaces in contrib for new zlib functions
Index: packages/services/compress/zlib/current/src/FAQ
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/FAQ,v
retrieving revision 1.3
diff -u -r1.3 FAQ
--- packages/services/compress/zlib/current/src/FAQ	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/FAQ	28 Jun 2005 15:43:27 -0000
@@ -21,18 +21,18 @@
  3. Where can I get a Visual Basic interface to zlib?
 
     See
-        * http://www.winimage.com/zLibDll/
         * http://www.dogma.net/markn/articles/zlibtool/zlibtool.htm
         * contrib/visual-basic.txt in the zlib distribution
+        * win32/DLL_FAQ.txt in the zlib distribution
 
- 4. compress() returns Z_BUF_ERROR
+ 4. compress() returns Z_BUF_ERROR.
 
     Make sure that before the call of compress, the length of the compressed
     buffer is equal to the total size of the compressed buffer and not
     zero. For Visual Basic, check that this parameter is passed by reference
     ("as any"), not by value ("as long").
 
- 5. deflate() or inflate() returns Z_BUF_ERROR
+ 5. deflate() or inflate() returns Z_BUF_ERROR.
 
     Before making the call, make sure that avail_in and avail_out are not
     zero. When setting the parameter flush equal to Z_FINISH, also make sure
@@ -47,8 +47,8 @@
 
     It's in zlib.h for the moment, and Francis S. Lin has converted it to a
     web page zlib.html. Volunteers to transform this to Unix-style man pages,
-    please contact Jean-loup Gailly (jloup@gzip.org). Examples of zlib usage
-    are in the files example.c and minigzip.c.
+    please contact us (zlib@gzip.org). Examples of zlib usage are in the files
+    example.c and minigzip.c.
 
  7. Why don't you use GNU autoconf or libtool or ...?
 
@@ -77,7 +77,8 @@
 
 11. Can zlib handle .zip archives?
 
-    See the directory contrib/minizip in the zlib distribution.
+    Not by itself, no.  See the directory contrib/minizip in the zlib
+    distribution.
 
 12. Can zlib handle .Z files?
 
@@ -92,6 +93,8 @@
 
 14. How do I install a shared zlib library on Unix?
 
+    After the above, then:
+
     make install
 
     However, many flavors of Unix come with a shared zlib already installed.
@@ -99,12 +102,31 @@
     trying to install it, you may want to check if it's already there! If you
     can #include <zlib.h>, it's there. The -lz option will probably link to it.
 
-15. I have a question about OttoPDF
+15. I have a question about OttoPDF.
 
     We are not the authors of OttoPDF. The real author is on the OttoPDF web
-    site Joel Hainley jhainley@myndkryme.com.
+    site: Joel Hainley, jhainley@myndkryme.com.
+
+16. Can zlib decode Flate data in an Adobe PDF file?
+
+    Yes. See http://www.fastio.com/ (ClibPDF), or http://www.pdflib.com/ .
+    To modify PDF forms, see http://sourceforge.net/projects/acroformtool/ .
+
+17. Why am I getting this "register_frame_info not found" error on Solaris?
+
+    After installing zlib 1.1.4 on Solaris 2.6, running applications using zlib
+    generates an error such as:
+
+        ld.so.1: rpm: fatal: relocation error: file /usr/local/lib/libz.so:
+        symbol __register_frame_info: referenced symbol not found
+
+    The symbol __register_frame_info is not part of zlib, it is generated by
+    the C compiler (cc or gcc). You must recompile applications using zlib
+    which have this problem. This problem is specific to Solaris. See
+    http://www.sunfreeware.com for Solaris versions of zlib and applications
+    using zlib.
 
-16. Why does gzip give an error on a file I make with compress/deflate?
+18. Why does gzip give an error on a file I make with compress/deflate?
 
     The compress and deflate functions produce data in the zlib format, which
     is different and incompatible with the gzip format. The gz* functions in
@@ -112,7 +134,7 @@
     formats use the same compressed data format internally, but have different
     headers and trailers around the compressed data.
 
-17. Ok, so why are there two different formats?
+19. Ok, so why are there two different formats?
 
     The gzip format was designed to retain the directory information about
     a single file, such as the name and last modification date. The zlib
@@ -120,7 +142,7 @@
     channel applications, and has a much more compact header and trailer and
     uses a faster integrity check than gzip.
 
-18. Well that's nice, but how do I make a gzip file in memory?
+20. Well that's nice, but how do I make a gzip file in memory?
 
     You can request that deflate write the gzip format instead of the zlib
     format using deflateInit2(). You can also request that inflate decode
@@ -133,7 +155,7 @@
     function and roll your own gzip encoding and decoding. Read the gzip
     RFC 1952 for details of the header and trailer format.
 
-19. Is zlib thread-safe?
+21. Is zlib thread-safe?
 
     Yes. However any library routines that zlib uses and any application-
     provided memory allocation routines must also be thread-safe. zlib's gz*
@@ -144,15 +166,15 @@
     Of course, you should only operate on any given zlib or gzip stream from a
     single thread at a time.
 
-20. Can I use zlib in my commercial application?
+22. Can I use zlib in my commercial application?
 
     Yes. Please read the license in zlib.h.
 
-21. Is zlib under the GNU license?
+23. Is zlib under the GNU license?
 
     No. Please read the license in zlib.h.
 
-22. The license says that altered source versions must be "plainly marked". So
+24. The license says that altered source versions must be "plainly marked". So
     what exactly do I need to do to meet that requirement?
 
     You need to change the ZLIB_VERSION and ZLIB_VERNUM #defines in zlib.h. In
@@ -175,24 +197,24 @@
     ZLIB_VERSION and ZLIB_VERNUM and note the origin and nature of the changes
     in zlib.h as you would for a full source distribution.
 
-23. Will zlib work on a big-endian or little-endian architecture, and can I
+25. Will zlib work on a big-endian or little-endian architecture, and can I
     exchange compressed data between them?
 
     Yes and yes.
 
-24. Will zlib work on a 64-bit machine?
+26. Will zlib work on a 64-bit machine?
 
     It should. It has been tested on 64-bit machines, and has no dependence
     on any data types being limited to 32-bits in length. If you have any
     difficulties, please provide a complete problem report to zlib@gzip.org
 
-25. Will zlib decompress data from the PKWare Data Compression Library?
+27. Will zlib decompress data from the PKWare Data Compression Library?
 
     No. The PKWare DCL uses a completely different compressed data format
     than does PKZIP and zlib. However, you can look in zlib's contrib/blast
     directory for a possible solution to your problem.
 
-26. Can I access data randomly in a compressed stream?
+28. Can I access data randomly in a compressed stream?
 
     No, not without some preparation. If when compressing you periodically
     use Z_FULL_FLUSH, carefully write all the pending data at those points,
@@ -200,27 +222,27 @@
     at those points. You have to be careful to not use Z_FULL_FLUSH too
     often, since it can significantly degrade compression.
 
-27. Does zlib work on MVS, OS/390, CICS, etc.?
+29. Does zlib work on MVS, OS/390, CICS, etc.?
 
     We don't know for sure. We have heard occasional reports of success on
     these systems. If you do use it on one of these, please provide us with
     a report, instructions, and patches that we can reference when we get
     these questions. Thanks.
 
-28. Is there some simpler, easier to read version of inflate I can look at
+30. Is there some simpler, easier to read version of inflate I can look at
     to understand the deflate format?
 
     First off, you should read RFC 1951. Second, yes. Look in zlib's
     contrib/puff directory.
 
-29. Does zlib infringe on any patents?
+31. Does zlib infringe on any patents?
 
     As far as we know, no. In fact, that was originally the whole point behind
     zlib. Look here for some more information:
 
     http://www.gzip.org/#faq11
 
-30. Can zlib work with greater than 4 GB of data?
+32. Can zlib work with greater than 4 GB of data?
 
     Yes. inflate() and deflate() will process any amount of data correctly.
     Each call of inflate() or deflate() is limited to input and output chunks
@@ -238,7 +260,7 @@
     only if the compiler's "long" type is 32 bits. If the compiler's "long"
     type is 64 bits, then the limit is 16 exabytes.
 
-31. Does zlib have any security vulnerabilities?
+33. Does zlib have any security vulnerabilities?
 
     The only one that we are aware of is potentially in gzprintf(). If zlib
     is compiled to use sprintf() or vsprintf(), then there is no protection
@@ -258,35 +280,35 @@
     Note that you should be using the most recent version of zlib. Versions
     1.1.3 and before were subject to a double-free vulnerability.
 
-32. Is there a Java version of zlib?
+34. Is there a Java version of zlib?
 
     Probably what you want is to use zlib in Java. zlib is already included
     as part of the Java SDK in the java.util.zip package. If you really want
     a version of zlib written in the Java language, look on the zlib home
     page for links: http://www.zlib.org/
 
-33. I get this or that compiler or source-code scanner warning when I crank it
-    up to maximally-pendantic. Can't you guys write proper code?
+35. I get this or that compiler or source-code scanner warning when I crank it
+    up to maximally-pedantic. Can't you guys write proper code?
 
     Many years ago, we gave up attempting to avoid warnings on every compiler
     in the universe. It just got to be a waste of time, and some compilers
     were downright silly. So now, we simply make sure that the code always
     works.
 
-34. Will zlib read the (insert any ancient or arcane format here) compressed
+36. Will zlib read the (insert any ancient or arcane format here) compressed
     data format?
 
     Probably not. Look in the comp.compression FAQ for pointers to various
     formats and associated software.
 
-35. How can I encrypt/decrypt zip files with zlib?
+37. How can I encrypt/decrypt zip files with zlib?
 
     zlib doesn't support encryption. The original PKZIP encryption is very weak
     and can be broken with freely available programs. To get strong encryption,
-    use gpg ( http://www.gnupg.org/ ) which already includes zlib compression.
+    use GnuPG, http://www.gnupg.org/ , which already includes zlib compression.
     For PKZIP compatible "encryption", look at http://www.info-zip.org/
 
-36. What's the difference between the "gzip" and "deflate" HTTP 1.1 encodings?
+38. What's the difference between the "gzip" and "deflate" HTTP 1.1 encodings?
 
     "gzip" is the gzip format, and "deflate" is the zlib format. They should
     probably have called the second one "zlib" instead to avoid confusion
@@ -302,14 +324,14 @@
 
     Bottom line: use the gzip format for HTTP 1.1 encoding.
 
-37. Does zlib support the new "Deflate64" format introduced by PKWare?
+39. Does zlib support the new "Deflate64" format introduced by PKWare?
 
     No. PKWare has apparently decided to keep that format proprietary, since
     they have not documented it as they have previous compression formats.
     In any case, the compression improvements are so modest compared to other
     more modern approaches, that it's not worth the effort to implement.
 
-38. Can you please sign these lengthy legal documents and fax them back to us
+40. Can you please sign these lengthy legal documents and fax them back to us
     so that we can use your software in our product?
 
     No. Go away. Shoo.
Index: packages/services/compress/zlib/current/src/INDEX
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/INDEX,v
retrieving revision 1.2
diff -u -r1.2 INDEX
--- packages/services/compress/zlib/current/src/INDEX	24 May 2004 19:33:35 -0000	1.2
+++ packages/services/compress/zlib/current/src/INDEX	28 Jun 2005 15:43:27 -0000
@@ -8,9 +8,12 @@
 configure       configure script for Unix
 zconf.in.h      template for zconf.h (used by configure)
 
+amiga/          makefiles for Amiga SAS C
+as400/          makefiles for IBM AS/400
 msdos/          makefiles for MSDOS
 old/            makefiles for various architectures and zlib documentation
                 files that have not yet been updated for zlib 1.2.x
+projects/       projects for various Integrated Development Environments
 qnx/            makefiles for QNX
 win32/          makefiles for Windows
 
Index: packages/services/compress/zlib/current/src/Makefile
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/Makefile,v
retrieving revision 1.3
diff -u -r1.3 Makefile
--- packages/services/compress/zlib/current/src/Makefile	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/Makefile	28 Jun 2005 15:43:27 -0000
@@ -30,7 +30,7 @@
 
 LIBS=libz.a
 SHAREDLIB=libz.so
-SHAREDLIBV=libz.so.1.2.1
+SHAREDLIBV=libz.so.1.2.2
 SHAREDLIBM=libz.so.1
 
 AR=ar rc
Index: packages/services/compress/zlib/current/src/Makefile.in
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/Makefile.in,v
retrieving revision 1.3
diff -u -r1.3 Makefile.in
--- packages/services/compress/zlib/current/src/Makefile.in	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/Makefile.in	28 Jun 2005 15:43:27 -0000
@@ -30,7 +30,7 @@
 
 LIBS=libz.a
 SHAREDLIB=libz.so
-SHAREDLIBV=libz.so.1.2.1
+SHAREDLIBV=libz.so.1.2.2
 SHAREDLIBM=libz.so.1
 
 AR=ar rc
Index: packages/services/compress/zlib/current/src/README
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/README,v
retrieving revision 1.3
diff -u -r1.3 README
--- packages/services/compress/zlib/current/src/README	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/README	28 Jun 2005 15:43:27 -0000
@@ -1,6 +1,6 @@
 ZLIB DATA COMPRESSION LIBRARY
 
-zlib 1.2.1 is a general purpose data compression library.  All the code is
+zlib 1.2.2 is a general purpose data compression library.  All the code is
 thread safe.  The data format used by the zlib library is described by RFCs
 (Request for Comments) 1950 to 1952 in the files
 http://www.ietf.org/rfc/rfc1950.txt (zlib format), rfc1951.txt (deflate format)
@@ -34,7 +34,7 @@
 issue of  Dr. Dobb's Journal; a copy of the article is available in
 http://dogma.net/markn/articles/zlibtool/zlibtool.htm
 
-The changes made in version 1.2.1 are documented in the file ChangeLog.
+The changes made in version 1.2.2 are documented in the file ChangeLog.
 
 Unsupported third party contributions are provided in directory "contrib".
 
@@ -46,7 +46,7 @@
 CPAN (Comprehensive Perl Archive Network) sites
 http://www.cpan.org/modules/by-module/Compress/
 
-A Python interface to zlib written by A.M. Kuchling <amk@magnet.com> is
+A Python interface to zlib written by A.M. Kuchling <amk@amk.ca> is
 available in Python 1.5 and later versions, see
 http://www.python.org/doc/lib/module-zlib.html
 
@@ -93,7 +93,7 @@
 
 Copyright notice:
 
- (C) 1995-2003 Jean-loup Gailly and Mark Adler
+ (C) 1995-2004 Jean-loup Gailly and Mark Adler
 
   This software is provided 'as-is', without any express or implied
   warranty.  In no event will the authors be held liable for any damages
Index: packages/services/compress/zlib/current/src/README.eCos
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/README.eCos,v
retrieving revision 1.3
diff -u -r1.3 README.eCos
--- packages/services/compress/zlib/current/src/README.eCos	25 May 2004 13:30:08 -0000	1.3
+++ packages/services/compress/zlib/current/src/README.eCos	28 Jun 2005 15:43:27 -0000
@@ -1,5 +1,5 @@
 See the main site http://www.gzip.org/zlib/ for places to download the 
-complete sources.  Currently based on zlib-1.2.1
+complete sources.  Currently based on zlib-1.2.2
 
 Note that these are not the complete zlib sources - the following
 directories have been deleted since they are irrelevant for the
@@ -10,6 +10,7 @@
 contrib/
 msdos/
 old/ 
+projects/
 qnx/ 
 win32/
 
@@ -18,6 +19,8 @@
 headers zlib.h and zconf.h have been moved out of the directory into
 ../include.
 
+crc32.c + crc32.h has also been removed as it is provided by services/crc/.
+
 Note: zconf.h always defines __ECOS__.  This is necessary to support
 programs built outside of the eCos tree which may wish to use this
 library (so those programs needn't worry about defining __ECOS__)
Index: packages/services/compress/zlib/current/src/configure
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/configure,v
retrieving revision 1.2
diff -u -r1.2 configure
--- packages/services/compress/zlib/current/src/configure	24 May 2004 19:33:35 -0000	1.2
+++ packages/services/compress/zlib/current/src/configure	28 Jun 2005 15:43:27 -0000
@@ -77,7 +77,7 @@
   CFLAGS="$cflags"
   case `(uname -s || echo unknown) 2>/dev/null` in
   Linux | linux | GNU | GNU/*) LDSHARED=${LDSHARED-"$cc -shared -Wl,-soname,libz.so.1"};;
-  CYGWIN* | Cygwin* | cygwin* )
+  CYGWIN* | Cygwin* | cygwin* | OS/2* )
              EXE='.exe';;
   QNX*)  # This is for QNX6. I suppose that the QNX rule below is for QNX2,QNX4
          # (alain.bonnefoy@icbt.com)
@@ -89,9 +89,7 @@
              SHAREDLIB=libz$shared_ext
              SHAREDLIBV=libz.$VER$shared_ext
              SHAREDLIBM=libz.$VER1$shared_ext
-             LDSHARED=${LDSHARED-"$cc -dynamiclib -install_name /usr/lib/$SHAREDLIBV -compatibility_version $VER2 -current_version $VER"}
-             libdir='/usr/lib'
-             includedir='/usr/include';;
+             LDSHARED=${LDSHARED-"$cc -dynamiclib -install_name $libdir/$SHAREDLIBV -compatibility_version $VER2 -current_version $VER"};;
   *)             LDSHARED=${LDSHARED-"$cc -shared"};;
   esac
 else
Index: packages/services/compress/zlib/current/src/deflate.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/deflate.c,v
retrieving revision 1.3
diff -u -r1.3 deflate.c
--- packages/services/compress/zlib/current/src/deflate.c	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/deflate.c	28 Jun 2005 15:43:27 -0000
@@ -1,5 +1,5 @@
 /* deflate.c -- compress data using the deflation algorithm
- * Copyright (C) 1995-2003 Jean-loup Gailly.
+ * Copyright (C) 1995-2004 Jean-loup Gailly.
  * For conditions of distribution and use, see copyright notice in zlib.h
  */
 
@@ -52,7 +52,7 @@
 #include "deflate.h"
 
 const char deflate_copyright[] =
-   " deflate 1.2.1 Copyright 1995-2003 Jean-loup Gailly ";
+   " deflate 1.2.2 Copyright 1995-2004 Jean-loup Gailly ";
 /*
   If you use the zlib library in a product, an acknowledgment is welcome
   in the documentation of your product. If for some reason you cannot
Index: packages/services/compress/zlib/current/src/deflate.h
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/deflate.h,v
retrieving revision 1.3
diff -u -r1.3 deflate.h
--- packages/services/compress/zlib/current/src/deflate.h	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/deflate.h	28 Jun 2005 15:43:28 -0000
@@ -95,7 +95,6 @@
     Bytef *pending_out;  /* next pending byte to output to the stream */
     int   pending;       /* nb of bytes in the pending buffer */
     int   wrap;          /* bit 0 true for zlib, bit 1 true for gzip */
-    Byte  data_type;     /* UNKNOWN, BINARY or ASCII */
     Byte  method;        /* STORED (for zip only) or DEFLATED */
     int   last_flush;    /* value of flush param for previous deflate call */
 
Index: packages/services/compress/zlib/current/src/gzio.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/gzio.c,v
retrieving revision 1.3
diff -u -r1.3 gzio.c
--- packages/services/compress/zlib/current/src/gzio.c	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/gzio.c	28 Jun 2005 15:43:28 -0000
@@ -455,6 +455,10 @@
                     s->z_err = Z_ERRNO;
                     break;
                 }
+                if (feof(s->file)) {        /* avoid error for empty file */
+                    s->z_err = Z_STREAM_END;
+                    break;
+                }
             }
             s->stream.next_in = s->inbuf;
         }
Index: packages/services/compress/zlib/current/src/infback.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/infback.c,v
retrieving revision 1.1
diff -u -r1.1 infback.c
--- packages/services/compress/zlib/current/src/infback.c	25 May 2004 13:31:20 -0000	1.1
+++ packages/services/compress/zlib/current/src/infback.c	28 Jun 2005 15:43:28 -0000
@@ -434,6 +434,9 @@
                 }
             }
 
+            /* handle error breaks in while */
+            if (state->mode == BAD) break;
+
             /* build code tables */
             state->next = state->codes;
             state->lencode = (code const FAR *)(state->next);
Index: packages/services/compress/zlib/current/src/inffast.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/inffast.c,v
retrieving revision 1.3
diff -u -r1.3 inffast.c
--- packages/services/compress/zlib/current/src/inffast.c	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/inffast.c	28 Jun 2005 15:43:28 -0000
@@ -1,5 +1,5 @@
 /* inffast.c -- fast decoding
- * Copyright (C) 1995-2003 Mark Adler
+ * Copyright (C) 1995-2004 Mark Adler
  * For conditions of distribution and use, see copyright notice in zlib.h
  */
 
@@ -19,7 +19,7 @@
    - none
    No measurable difference:
    - Pentium III (Anderson)
-   - 68060 (Nikl)
+   - M68060 (Nikl)
  */
 #ifdef POSTINC
 #  define OFF 0
Index: packages/services/compress/zlib/current/src/inflate.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/inflate.c,v
retrieving revision 1.5
diff -u -r1.5 inflate.c
--- packages/services/compress/zlib/current/src/inflate.c	24 May 2004 19:33:35 -0000	1.5
+++ packages/services/compress/zlib/current/src/inflate.c	28 Jun 2005 15:43:30 -0000
@@ -109,6 +109,7 @@
     state = (struct inflate_state FAR *)strm->state;
     strm->total_in = strm->total_out = state->total = 0;
     strm->msg = Z_NULL;
+    strm->adler = 1;        /* to support ill-conceived Java test suite */
     state->mode = HEAD;
     state->last = 0;
     state->havedict = 0;
@@ -861,6 +862,9 @@
                 }
             }
 
+            /* handle error breaks in while */
+            if (state->mode == BAD) break;
+
             /* build code tables */
             state->next = state->codes;
             state->lencode = (code const FAR *)(state->next);
Index: packages/services/compress/zlib/current/src/inftrees.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/inftrees.c,v
retrieving revision 1.3
diff -u -r1.3 inftrees.c
--- packages/services/compress/zlib/current/src/inftrees.c	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/inftrees.c	28 Jun 2005 15:43:30 -0000
@@ -1,5 +1,5 @@
 /* inftrees.c -- generate Huffman trees for efficient decoding
- * Copyright (C) 1995-2003 Mark Adler
+ * Copyright (C) 1995-2004 Mark Adler
  * For conditions of distribution and use, see copyright notice in zlib.h
  */
 
@@ -9,7 +9,7 @@
 #define MAXBITS 15
 
 const char inflate_copyright[] =
-   " inflate 1.2.1 Copyright 1995-2003 Mark Adler ";
+   " inflate 1.2.2 Copyright 1995-2004 Mark Adler ";
 /*
   If you use the zlib library in a product, an acknowledgment is welcome
   in the documentation of your product. If for some reason you cannot
@@ -62,7 +62,7 @@
         35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0};
     static const unsigned short lext[31] = { /* Length codes 257..285 extra */
         16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18,
-        19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 76, 66};
+        19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 199, 198};
     static const unsigned short dbase[32] = { /* Distance codes 0..29 base */
         1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193,
         257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145,
@@ -114,7 +114,15 @@
     for (max = MAXBITS; max >= 1; max--)
         if (count[max] != 0) break;
     if (root > max) root = max;
-    if (max == 0) return -1;            /* no codes! */
+    if (max == 0) {                     /* no symbols to code at all */
+        this.op = (unsigned char)64;    /* invalid code marker */
+        this.bits = (unsigned char)1;
+        this.val = (unsigned short)0;
+        *(*table)++ = this;             /* make a table to force an error */
+        *(*table)++ = this;
+        *bits = 1;
+        return 0;     /* no symbols, but wait for decoding to report error */
+    }
     for (min = 1; min <= MAXBITS; min++)
         if (count[min] != 0) break;
     if (root < min) root = min;
@@ -295,7 +303,6 @@
             drop = 0;
             len = root;
             next = *table;
-            curr = root;
             this.bits = (unsigned char)len;
         }
 
Index: packages/services/compress/zlib/current/src/trees.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/trees.c,v
retrieving revision 1.3
diff -u -r1.3 trees.c
--- packages/services/compress/zlib/current/src/trees.c	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/trees.c	28 Jun 2005 15:43:31 -0000
@@ -931,7 +931,7 @@
     if (s->level > 0) {
 
          /* Check if the file is ascii or binary */
-        if (s->data_type == Z_UNKNOWN) set_data_type(s);
+        if (s->strm->data_type == Z_UNKNOWN) set_data_type(s);
 
         /* Construct the literal and distance trees */
         build_tree(s, (tree_desc *)(&(s->l_desc)));
@@ -1131,7 +1131,7 @@
     while (n < 7)        bin_freq += s->dyn_ltree[n++].Freq;
     while (n < 128)    ascii_freq += s->dyn_ltree[n++].Freq;
     while (n < LITERALS) bin_freq += s->dyn_ltree[n++].Freq;
-    s->data_type = (Byte)(bin_freq > (ascii_freq >> 2) ? Z_BINARY : Z_ASCII);
+    s->strm->data_type = bin_freq > (ascii_freq >> 2) ? Z_BINARY : Z_ASCII;
 }
 
 /* ===========================================================================
Index: packages/services/compress/zlib/current/src/zlib.3
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/zlib.3,v
retrieving revision 1.3
diff -u -r1.3 zlib.3
--- packages/services/compress/zlib/current/src/zlib.3	24 May 2004 19:33:35 -0000	1.3
+++ packages/services/compress/zlib/current/src/zlib.3	28 Jun 2005 15:43:31 -0000
@@ -1,4 +1,4 @@
-.TH ZLIB 3 "17 November 2003"
+.TH ZLIB 3 "3 October 2004"
 .SH NAME
 zlib \- compression/decompression library
 .SH SYNOPSIS
@@ -133,8 +133,8 @@
 Send questions and/or comments to zlib@gzip.org,
 or (for the Windows DLL version) to Gilles Vollant (info@winimage.com).
 .SH AUTHORS
-Version 1.2.1
-Copyright (C) 1995-2003 Jean-loup Gailly (jloup@gzip.org)
+Version 1.2.2
+Copyright (C) 1995-2004 Jean-loup Gailly (jloup@gzip.org)
 and Mark Adler (madler@alumni.caltech.edu).
 .LP
 This software is provided "as-is,"
Index: packages/services/compress/zlib/current/src/zutil.h
===================================================================
RCS file: /cvs/ecos/ecos/packages/services/compress/zlib/current/src/zutil.h,v
retrieving revision 1.5
diff -u -r1.5 zutil.h
--- packages/services/compress/zlib/current/src/zutil.h	25 May 2004 13:30:08 -0000	1.5
+++ packages/services/compress/zlib/current/src/zutil.h	28 Jun 2005 15:43:31 -0000
@@ -196,9 +196,14 @@
 #    define NO_vsnprintf
 #  endif
 #endif
+#ifdef VMS
+#  define NO_vsnprintf
+#endif
 
 #ifdef HAVE_STRERROR
-   extern char *strerror OF((int));
+#  ifndef VMS
+     extern char *strerror OF((int));
+#  endif
 #  define zstrerror(errnum) strerror(errnum)
 #else
 #  define zstrerror(errnum) ""
-- 
Bye, Peter Korsgaard

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]