diff options
Diffstat (limited to 'graphics/tiff/patches/patch-ay')
-rw-r--r-- | graphics/tiff/patches/patch-ay | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/graphics/tiff/patches/patch-ay b/graphics/tiff/patches/patch-ay new file mode 100644 index 00000000000..67f3f662e35 --- /dev/null +++ b/graphics/tiff/patches/patch-ay @@ -0,0 +1,29 @@ +$NetBSD: patch-ay,v 1.3 2006/08/02 15:42:25 salo Exp $ + +Security fix for SA21304. + +--- libtiff/tif_fax3.c.orig 2006-03-21 17:42:50.000000000 +0100 ++++ libtiff/tif_fax3.c 2006-08-02 17:18:41.000000000 +0200 +@@ -1136,6 +1136,7 @@ static int + Fax3VSetField(TIFF* tif, ttag_t tag, va_list ap) + { + Fax3BaseState* sp = Fax3State(tif); ++ const TIFFFieldInfo* fip; + + assert(sp != 0); + assert(sp->vsetparent != 0); +@@ -1181,7 +1182,13 @@ Fax3VSetField(TIFF* tif, ttag_t tag, va_ + default: + return (*sp->vsetparent)(tif, tag, ap); + } +- TIFFSetFieldBit(tif, _TIFFFieldWithTag(tif, tag)->field_bit); ++ ++ if ((fip = _TIFFFieldWithTag(tif, tag))) { ++ TIFFSetFieldBit(tif, fip->field_bit); ++ } else { ++ return (0); ++ } ++ + tif->tif_flags |= TIFF_DIRTYDIRECT; + return (1); + } |