libtiff: * libtiff 3.9.4 released.

https://github.com/libsdl-org/libtiff/commit/5ebb9f949b96993238ddef55b7601db3d9989d41

From 5ebb9f949b96993238ddef55b7601db3d9989d41 Mon Sep 17 00:00:00 2001
From: Bob Friesenhahn <[EMAIL REDACTED]>
Date: Tue, 15 Jun 2010 19:07:00 +0000
Subject: [PATCH] * libtiff 3.9.4 released.

---
 ChangeLog                     |   4 ++
 RELEASE-DATE                  |   2 +-
 VERSION                       |   2 +-
 build/Makefile.in             |   2 +-
 configure                     |  22 +++---
 configure.ac                  |   4 +-
 contrib/dbs/xtiff/Makefile.in |   2 +-
 html/Makefile.in              |   2 +-
 html/index.html               |   4 +-
 html/v3.9.4.html              | 125 ++++++++++++++++++++++++++++++++++
 libtiff/tiffvers.h            |   4 +-
 11 files changed, 151 insertions(+), 22 deletions(-)
 create mode 100644 html/v3.9.4.html

diff --git a/ChangeLog b/ChangeLog
index 2c414b29..2411f2c9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2010-06-15  Bob Friesenhahn  <bfriesen@simple.dallas.tx.us>
+
+	* libtiff 3.9.4 released.
+
 2010-06-13  Frank Warmerdam  <warmerdam@pobox.com>
 
 	* libtiff/tif_jpeg.c: avoid re-preparing jpeg tables unnecessarily
diff --git a/RELEASE-DATE b/RELEASE-DATE
index 9e5fb1cf..a1b1eb97 100644
--- a/RELEASE-DATE
+++ b/RELEASE-DATE
@@ -1 +1 @@
-20100611
+20100615
diff --git a/VERSION b/VERSION
index 820476af..e0d61b5b 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-3.9.3
+3.9.4
diff --git a/build/Makefile.in b/build/Makefile.in
index 1adca1f9..883a3f53 100644
--- a/build/Makefile.in
+++ b/build/Makefile.in
@@ -15,7 +15,7 @@
 
 @SET_MAKE@
 
-# $Id: Makefile.in,v 1.1.2.15 2010-06-11 22:02:15 bfriesen Exp $
+# $Id: Makefile.in,v 1.1.2.16 2010-06-15 19:07:05 bfriesen Exp $
 #
 # Tag Image File Format (TIFF) Software
 #
diff --git a/configure b/configure
index 48f008f0..b0bd9f19 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.65 for LibTIFF Software 3.9.3.
+# Generated by GNU Autoconf 2.65 for LibTIFF Software 3.9.4.
 #
 # Report bugs to <tiff@lists.maptools.org>.
 #
@@ -562,8 +562,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='LibTIFF Software'
 PACKAGE_TARNAME='tiff'
-PACKAGE_VERSION='3.9.3'
-PACKAGE_STRING='LibTIFF Software 3.9.3'
+PACKAGE_VERSION='3.9.4'
+PACKAGE_STRING='LibTIFF Software 3.9.4'
 PACKAGE_BUGREPORT='tiff@lists.maptools.org'
 PACKAGE_URL=''
 
@@ -1355,7 +1355,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures LibTIFF Software 3.9.3 to adapt to many kinds of systems.
+\`configure' configures LibTIFF Software 3.9.4 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1430,7 +1430,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of LibTIFF Software 3.9.3:";;
+     short | recursive ) echo "Configuration of LibTIFF Software 3.9.4:";;
    esac
   cat <<\_ACEOF
 
@@ -1588,7 +1588,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-LibTIFF Software configure 3.9.3
+LibTIFF Software configure 3.9.4
 generated by GNU Autoconf 2.65
 
 Copyright (C) 2009 Free Software Foundation, Inc.
@@ -2312,7 +2312,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by LibTIFF Software $as_me 3.9.3, which was
+It was created by LibTIFF Software $as_me 3.9.4, which was
 generated by GNU Autoconf 2.65.  Invocation command line was
 
   $ $0 $@
@@ -3239,7 +3239,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='tiff'
- VERSION='3.9.3'
+ VERSION='3.9.4'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3305,7 +3305,7 @@ fi
 
 LIBTIFF_MAJOR_VERSION=3
 LIBTIFF_MINOR_VERSION=9
-LIBTIFF_MICRO_VERSION=3
+LIBTIFF_MICRO_VERSION=4
 LIBTIFF_ALPHA_VERSION=
 LIBTIFF_VERSION=$LIBTIFF_MAJOR_VERSION.$LIBTIFF_MINOR_VERSION.$LIBTIFF_MICRO_VERSION$LIBTIFF_ALPHA_VERSION
 LIBTIFF_RELEASE_DATE=`date +"%Y%m%d"`
@@ -19267,7 +19267,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by LibTIFF Software $as_me 3.9.3, which was
+This file was extended by LibTIFF Software $as_me 3.9.4, which was
 generated by GNU Autoconf 2.65.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -19333,7 +19333,7 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-LibTIFF Software config.status 3.9.3
+LibTIFF Software config.status 3.9.4
 configured by $0, generated by GNU Autoconf 2.65,
   with options \\"\$ac_cs_config\\"
 
diff --git a/configure.ac b/configure.ac
index 5cafabbd..e0e0ae1b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -25,7 +25,7 @@ dnl OF THIS SOFTWARE.
 dnl Process this file with autoconf to produce a configure script.
 
 AC_PREREQ(2.64)
-AC_INIT([LibTIFF Software],[3.9.3],[tiff@lists.maptools.org],[tiff])
+AC_INIT([LibTIFF Software],[3.9.4],[tiff@lists.maptools.org],[tiff])
 AC_CONFIG_AUX_DIR(config)
 AC_CONFIG_MACRO_DIR(m4)
 AC_LANG(C)
@@ -41,7 +41,7 @@ dnl Versioning.
 dnl Don't fill the ALPHA_VERSION field, if not applicable.
 LIBTIFF_MAJOR_VERSION=3
 LIBTIFF_MINOR_VERSION=9
-LIBTIFF_MICRO_VERSION=3
+LIBTIFF_MICRO_VERSION=4
 LIBTIFF_ALPHA_VERSION=
 LIBTIFF_VERSION=$LIBTIFF_MAJOR_VERSION.$LIBTIFF_MINOR_VERSION.$LIBTIFF_MICRO_VERSION$LIBTIFF_ALPHA_VERSION
 dnl This will be used with the 'make release' target
diff --git a/contrib/dbs/xtiff/Makefile.in b/contrib/dbs/xtiff/Makefile.in
index c0357f4a..1e1f07d4 100644
--- a/contrib/dbs/xtiff/Makefile.in
+++ b/contrib/dbs/xtiff/Makefile.in
@@ -15,7 +15,7 @@
 
 @SET_MAKE@
 
-# $Id: Makefile.in,v 1.36.2.15 2010-06-11 22:02:15 bfriesen Exp $
+# $Id: Makefile.in,v 1.36.2.16 2010-06-15 19:07:05 bfriesen Exp $
 #
 # Tag Image File Format (TIFF) Software
 #
diff --git a/html/Makefile.in b/html/Makefile.in
index bdde77e0..f7afa86b 100644
--- a/html/Makefile.in
+++ b/html/Makefile.in
@@ -15,7 +15,7 @@
 
 @SET_MAKE@
 
-# $Id: Makefile.in,v 1.49.2.15 2010-06-11 22:02:15 bfriesen Exp $
+# $Id: Makefile.in,v 1.49.2.16 2010-06-15 19:07:05 bfriesen Exp $
 #
 # Tag Image File Format (TIFF) Software
 #
diff --git a/html/index.html b/html/index.html
index dfa68961..a1642864 100644
--- a/html/index.html
+++ b/html/index.html
@@ -24,7 +24,7 @@ <h1>LibTIFF - TIFF Library and Utilities</h1>
     </tr>
     <tr>
       <th>Latest Stable Release</th>
-      <td><a href="v3.9.3.html">v3.9.3</a></td>
+      <td><a href="v3.9.4.html">v3.9.4</a></td>
     </tr>
     <tr>
       <th>Master Download Site</th>
@@ -117,7 +117,7 @@ <h1>LibTIFF - TIFF Library and Utilities</h1>
   </ul>
   <hr>
   <p>
-    Last updated  $Date: 2010-06-11 22:02:15 $.
+    Last updated  $Date: 2010-06-15 19:07:05 $.
   </p>
 </body>
 </html>
diff --git a/html/v3.9.4.html b/html/v3.9.4.html
new file mode 100644
index 00000000..7d8cd7dd
--- /dev/null
+++ b/html/v3.9.4.html
@@ -0,0 +1,125 @@
+<HTML>
+<HEAD>
+<TITLE>
+	Changes in TIFF v3.9.4
+</TITLE>
+</HEAD>
+
+<BODY BGCOLOR=white>
+<FONT FACE="Helvetica, Arial, Sans">
+<FONT FACE="Helvetica, Arial, Sans"> 
+
+<BASEFONT SIZE=4>
+<B><FONT SIZE=+3>T</FONT>IFF <FONT SIZE=+2>C</FONT>HANGE <FONT SIZE=+2>I</FONT>NFORMATION</B>
+<BASEFONT SIZE=3>
+
+<UL>
+<HR SIZE=4 WIDTH=65% ALIGN=left>
+<B>Current Version</B>: v3.9.4<BR>
+<B>Previous Version</B>: <A HREF=v3.9.3.html>v3.9.3</a><BR>
+<B>Master FTP Site</B>: <A HREF="ftp://ftp.remotesensing.org/pub/libtiff">
+ftp.remotesensing.org</a>, directory pub/libtiff</A><BR>
+<B>Master HTTP Site</B>: <A HREF="http://www.remotesensing.org/libtiff">
+http://www.remotesensing.org/libtiff</a> 
+<HR SIZE=4 WIDTH=65% ALIGN=left>
+</UL>
+
+<P>
+This document describes the changes made to the software between the
+<I>previous</I> and <I>current</I> versions (see above).  If you don't
+find something listed here, then it was not done in this timeframe, or
+it was not considered important enough to be mentioned.  The following
+information is located here:
+<UL>
+<LI><A HREF="#hightlights">Major Changes</A>
+<LI><A HREF="#configure">Changes in the software configuration</A>
+<LI><A HREF="#libtiff">Changes in libtiff</A>
+<LI><A HREF="#tools">Changes in the tools</A>
+<LI><A HREF="#contrib">Changes in the contrib area</A>
+</UL>
+<p> 
+<P><HR WIDTH=65% ALIGN=left>
+
+<!--------------------------------------------------------------------------->
+
+<A NAME="highlights"><B><FONT SIZE=+3>M</FONT>AJOR CHANGES:</B></A>
+
+<UL>
+
+	<li> Complete the fixes for CVE-2009-2347.
+
+        <li> Tiffcrop now supports custom page sizes.
+
+</UL>
+
+
+<P><HR WIDTH=65% ALIGN=left>
+<!--------------------------------------------------------------------------->
+
+<A NAME="configure"><B><FONT SIZE=+3>C</FONT>HANGES IN THE SOFTWARE CONFIGURATION:</B></A>
+
+<UL>
+
+	<li> None.
+
+</UL>
+
+<P><HR WIDTH=65% ALIGN=left>
+
+<!--------------------------------------------------------------------------->
+
+<A NAME="libtiff"><B><FONT SIZE=+3>C</FONT>HANGES IN LIBTIFF:</B></A>
+
+<UL>
+	<li> Fixed inadequate validation of the SubjectDistance field.
+
+	<li> Fixed bad handling of out of order tags definated late by
+	a codec.
+
+	<li> Avoid re-preparing jpeg tables unnecessarily.
+
+</UL>
+
+<P><HR WIDTH=65% ALIGN=left>
+
+<!-------------------------------------------------------------------------->
+	
+<A NAME="tools"><B><FONT SIZE=+3>C</FONT>HANGES IN THE TOOLS:</B></A>
+
+<UL>
+
+        <li> tiffcrop: Added an option to allow the user to specify a
+        custom page size on the command line.  Fix the case where a
+        page size specified with a fractional part was being coerced
+        to an integer by retyping the variables that define the paper
+        size.  Corrected European page size dimensions.
+
+        <li> tiff2rgba: Completed fixes for "CVE-2009-2347 libtiff:
+        integer overflows in various inter-color space conversion
+        tools". http://bugzilla.maptools.org/show_bug.cgi?id=2079
+
+        <li> tiff2pdf: Fix assorted bugs in tiff2pdf: missing "return"
+        in t2p_read_tiff_size() causes t2p->tiff_datasize to be set entirely
+        wrong for COMPRESSION_JPEG case, resulting in memory stomp if actual
+        size is larger.  Also, there are a bunch of places that try to
+        memset() a malloc'd buffer before checking for malloc failure, which
+        would result in core dump if there actually were a failure.
+
+</UL>
+
+<P><HR WIDTH=65% ALIGN=left>
+
+<!--------------------------------------------------------------------------->
+
+<A NAME="contrib"><B><FONT SIZE=+3>C</FONT>HANGES IN THE CONTRIB AREA:</B></A>
+
+<UL> 
+
+	<li> None
+
+</UL>
+
+Last updated $Date: 2010-06-15 19:07:05 $.
+
+</BODY>
+</HTML>
diff --git a/libtiff/tiffvers.h b/libtiff/tiffvers.h
index ce293e7a..314a22a0 100644
--- a/libtiff/tiffvers.h
+++ b/libtiff/tiffvers.h
@@ -1,4 +1,4 @@
-#define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.9.3\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc."
+#define TIFFLIB_VERSION_STR "LIBTIFF, Version 3.9.4\nCopyright (c) 1988-1996 Sam Leffler\nCopyright (c) 1991-1996 Silicon Graphics, Inc."
 /*
  * This define can be used in code that requires
  * compilation-related definitions specific to a
@@ -6,4 +6,4 @@
  * version checking should be done based on the
  * string returned by TIFFGetVersion.
  */
-#define TIFFLIB_VERSION 20100611
+#define TIFFLIB_VERSION 20100615