9eeea42aaf
* This version restores in the default build the availability of the tools that had been dropped in v4.6.0 See https://libtiff.gitlab.io/libtiff/rfcs/rfc2_restoring_needed_tools.html#rfc2-restoring-needed-tools * Software configuration changes: + autoconf build: configure.ac: avoid -Werror passed to CFLAGS to interfere with feature detection + autoconf build: fix error when running make clean (fixes issue #630) + autoconf build: back off the minimum required automake version to 1.11 + autoconf.ac: fix detection of windows.h for mingw (fixes issue #605) + libtiff-4.pc: Fix Requires.private missing Lerc. It provides a .pc file starting from version 4 (in autoconf builds, we assume that liblerc is at least version 4) + CMake: Fix TIFF_INCLUDE_DIRS + CMake: MinGW compilers don't need a .def file for shared library + CMake: move libdeflate and Lerc to Requires.private + CMake: enable resource compilation on all Windows. * Library changes: + Add TIFFOpenOptionsSetMaxCumulatedMemAlloc(). This function complements TIFFOpenOptionsSetMaxSingleMemAlloc() to define the maximum cumulated memory allocations in byte, for a given TIFF handle, that libtiff internal memory allocation functions are allowed. + TIFFWriteDirectory(): Avoid overwriting following data if an IFD is enlarged. + TIFFXYZToRGB: avoid integer overflow (fixes issue #644) + uv_decode() and uv_encode(): avoid potential out-of-bounds array index (fixes issue #645) + Fix cases where tif_curdir is set incorrectly. Fix cases where the current directory number (tif_curdir) is set inconsistently or incorrectly, depending on the previous history. + TIFFRead[Scanline/EncodedStrip/EncodeTile]: 0-initialize output buffer if setupdecode fails ; most codecs: zero-initialize (not-yet-written parts of) output buffer if failure (fixes issue #375) + OJPEG: reset subsampling_convert_state=0 in OJPEGPreDecode (fixes issue #183) + ThunderRLE: fix failure when decoding last run. Bug seen with GhostPDL + LERC codec: deal with issues with multi-band PlanarConfig=Contig and NaN values OBS-URL: https://build.opensuse.org/package/show/graphics/tiff?expand=0&rev=182
50 lines
2.2 KiB
Diff
50 lines
2.2 KiB
Diff
Upstream:
|
|
3705f82b6483c7906cf08cd6b9dcdcd59c61d779
|
|
Index: tiff-4.6.0/libtiff/tif_dirinfo.c
|
|
===================================================================
|
|
--- tiff-4.6.0.orig/libtiff/tif_dirinfo.c
|
|
+++ tiff-4.6.0/libtiff/tif_dirinfo.c
|
|
@@ -887,7 +887,7 @@ const TIFFField *_TIFFFindOrRegisterFiel
|
|
if (fld == NULL)
|
|
{
|
|
fld = _TIFFCreateAnonField(tif, tag, dt);
|
|
- if (!_TIFFMergeFields(tif, fld, 1))
|
|
+ if (fld == NULL || !_TIFFMergeFields(tif, fld, 1))
|
|
return NULL;
|
|
}
|
|
|
|
Index: tiff-4.6.0/libtiff/tif_dirread.c
|
|
===================================================================
|
|
--- tiff-4.6.0.orig/libtiff/tif_dirread.c
|
|
+++ tiff-4.6.0/libtiff/tif_dirread.c
|
|
@@ -4260,11 +4260,9 @@ int TIFFReadDirectory(TIFF *tif)
|
|
dp->tdir_tag, dp->tdir_tag);
|
|
/* the following knowingly leaks the
|
|
anonymous field structure */
|
|
- if (!_TIFFMergeFields(
|
|
- tif,
|
|
- _TIFFCreateAnonField(tif, dp->tdir_tag,
|
|
- (TIFFDataType)dp->tdir_type),
|
|
- 1))
|
|
+ const TIFFField *fld = _TIFFCreateAnonField(
|
|
+ tif, dp->tdir_tag, (TIFFDataType)dp->tdir_type);
|
|
+ if (fld == NULL || !_TIFFMergeFields(tif, fld, 1))
|
|
{
|
|
TIFFWarningExtR(
|
|
tif, module,
|
|
@@ -5138,11 +5136,9 @@ int TIFFReadCustomDirectory(TIFF *tif, t
|
|
"Unknown field with tag %" PRIu16 " (0x%" PRIx16
|
|
") encountered",
|
|
dp->tdir_tag, dp->tdir_tag);
|
|
- if (!_TIFFMergeFields(
|
|
- tif,
|
|
- _TIFFCreateAnonField(tif, dp->tdir_tag,
|
|
- (TIFFDataType)dp->tdir_type),
|
|
- 1))
|
|
+ const TIFFField *fld = _TIFFCreateAnonField(
|
|
+ tif, dp->tdir_tag, (TIFFDataType)dp->tdir_type);
|
|
+ if (fld == NULL || !_TIFFMergeFields(tif, fld, 1))
|
|
{
|
|
TIFFWarningExtR(tif, module,
|
|
"Registering anonymous field with tag %" PRIu16
|