Ticket #2018: png-1.2.26-to-1.2.29.diff

File png-1.2.26-to-1.2.29.diff, 22.8 KB (added by scottmc, 16 years ago)

diff file to update libpng from 1.2.26 to 1.2.29

  • src/add-ons/translators/png/PNGView.cpp

     
    9494    fCopyrightView->SetText(png_get_copyright(NULL));
    9595
    9696    BFont font;
    97     font.SetSize(font.Size() * 0.8);
     97    font.SetSize(font.Size() * 0.7);
    9898    fCopyrightView->SetFontAndColor(&font, B_FONT_SIZE, NULL);
    9999    AddChild(fCopyrightView);
    100100
  • src/add-ons/translators/exr/ConfigView.cpp

     
    2525    float height = fontHeight.descent + fontHeight.ascent + fontHeight.leading;
    2626
    2727    BRect rect(10, 10, 200, 10 + height);
    28     BStringView *stringView = new BStringView(rect, "title", "EXR Images");
     28    BStringView *stringView = new BStringView(rect, "title", "EXR Image Translator");
    2929    stringView->SetFont(be_bold_font);
    3030    stringView->ResizeToPreferred();
    3131    AddChild(stringView);
  • src/libs/png/pngwrite.c

     
    11
    22/* pngwrite.c - general routines to write a PNG file
    33 *
    4  * Last changed in libpng 1.2.25 [February 18, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    112112            ((up->name[3] & 0x20) || keep == PNG_HANDLE_CHUNK_ALWAYS ||
    113113            (png_ptr->flags & PNG_FLAG_KEEP_UNSAFE_CHUNKS)))
    114114         {
     115            if (up->size == 0)
     116               png_warning(png_ptr, "Writing zero-length unknown chunk");
    115117            png_write_chunk(png_ptr, up->name, up->data, up->size);
    116118         }
    117119       }
  • src/libs/png/pngpread.c

     
    11
    22/* pngpread.c - read a png file in push mode
    33 *
    4  * Last changed in libpng 1.2.26 [April 2, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    15021502                 png_sizeof(png_ptr->unknown_chunk.name));
    15031503      png_ptr->unknown_chunk.name[png_sizeof(png_ptr->unknown_chunk.name)-1]='\0';
    15041504
    1505       png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length);
    15061505      png_ptr->unknown_chunk.size = (png_size_t)length;
    1507       png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length);
     1506      if (length == 0)
     1507         png_ptr->unknown_chunk.data = NULL;
     1508      else
     1509      {
     1510         png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length);
     1511         png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length);
     1512      }
    15081513#if defined(PNG_READ_USER_CHUNKS_SUPPORTED)
    15091514      if(png_ptr->read_user_chunk_fn != NULL)
    15101515      {
  • src/libs/png/pngset.c

     
    11
    22/* pngset.c - storage of image information into info struct
    33 *
    4  * Last changed in libpng 1.2.25 [February 18, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    914914   if (png_ptr == NULL || info_ptr == NULL)
    915915      return;
    916916
     917   png_free_data(png_ptr, info_ptr, PNG_FREE_TRNS, 0);
     918
    917919   if (trans != NULL)
    918920   {
    919921       /*
     
    921923        * we do it for backward compatibility with the way the png_handle_tRNS
    922924        * function used to do the allocation.
    923925        */
    924 #ifdef PNG_FREE_ME_SUPPORTED
    925        png_free_data(png_ptr, info_ptr, PNG_FREE_TRNS, 0);
    926 #endif
     926
    927927       /* Changed from num_trans to PNG_MAX_PALETTE_LENGTH in version 1.2.1 */
    928928       png_ptr->trans = info_ptr->trans = (png_bytep)png_malloc(png_ptr,
    929929           (png_uint_32)PNG_MAX_PALETTE_LENGTH);
    930        if (num_trans <= PNG_MAX_PALETTE_LENGTH)
     930       if (num_trans > 0 && num_trans <= PNG_MAX_PALETTE_LENGTH)
    931931         png_memcpy(info_ptr->trans, trans, (png_size_t)num_trans);
    932 #ifdef PNG_FREE_ME_SUPPORTED
    933        info_ptr->free_me |= PNG_FREE_TRNS;
    934 #else
    935        png_ptr->flags |= PNG_FLAG_FREE_TRNS;
    936 #endif
    937932   }
    938933
    939934   if (trans_values != NULL)
    940935   {
     936      int sample_max = (1 << info_ptr->bit_depth);
     937      if ((info_ptr->color_type == PNG_COLOR_TYPE_GRAY &&
     938          (int)trans_values->gray > sample_max) ||
     939          (info_ptr->color_type == PNG_COLOR_TYPE_RGB &&
     940          ((int)trans_values->red > sample_max ||
     941          (int)trans_values->green > sample_max ||
     942          (int)trans_values->blue > sample_max)))
     943        png_warning(png_ptr,
     944           "tRNS chunk has out-of-range samples for bit_depth");
    941945      png_memcpy(&(info_ptr->trans_values), trans_values,
    942946         png_sizeof(png_color_16));
    943947      if (num_trans == 0)
    944948        num_trans = 1;
    945949   }
     950
    946951   info_ptr->num_trans = (png_uint_16)num_trans;
    947    info_ptr->valid |= PNG_INFO_tRNS;
     952   if (num_trans != 0)
     953   {
     954      info_ptr->valid |= PNG_INFO_tRNS;
     955#ifdef PNG_FREE_ME_SUPPORTED
     956      info_ptr->free_me |= PNG_FREE_TRNS;
     957#else
     958      png_ptr->flags |= PNG_FLAG_FREE_TRNS;
     959#endif
     960   }
    948961}
    949962#endif
    950963
     
    10401053
    10411054    for (i = 0; i < num_unknowns; i++)
    10421055    {
    1043         png_unknown_chunkp to = np + info_ptr->unknown_chunks_num + i;
    1044         png_unknown_chunkp from = unknowns + i;
     1056       png_unknown_chunkp to = np + info_ptr->unknown_chunks_num + i;
     1057       png_unknown_chunkp from = unknowns + i;
    10451058
    1046         png_memcpy((png_charp)to->name,
    1047                    (png_charp)from->name,
    1048                    png_sizeof(from->name));
    1049         to->name[png_sizeof(to->name)-1] = '\0';
     1059       png_memcpy((png_charp)to->name,
     1060                  (png_charp)from->name,
     1061                  png_sizeof(from->name));
     1062       to->name[png_sizeof(to->name)-1] = '\0';
     1063       to->size = from->size;
     1064       /* note our location in the read or write sequence */
     1065       to->location = (png_byte)(png_ptr->mode & 0xff);
    10501066
    1051         to->data = (png_bytep)png_malloc_warn(png_ptr, from->size);
    1052         if (to->data == NULL)
    1053         {
    1054            png_warning(png_ptr,
     1067       if (from->size == 0)
     1068          to->data=NULL;
     1069       else
     1070       {
     1071          to->data = (png_bytep)png_malloc_warn(png_ptr, from->size);
     1072          if (to->data == NULL)
     1073          {
     1074             png_warning(png_ptr,
    10551075              "Out of memory while processing unknown chunk.");
    1056         }
    1057         else
    1058         {
    1059            png_memcpy(to->data, from->data, from->size);
    1060            to->size = from->size;
    1061 
    1062            /* note our location in the read or write sequence */
    1063            to->location = (png_byte)(png_ptr->mode & 0xff);
    1064         }
     1076             to->size=0;
     1077          }
     1078          else
     1079             png_memcpy(to->data, from->data, from->size);
     1080       }
    10651081    }
    10661082
    10671083    info_ptr->unknown_chunks = np;
     
    11931209{
    11941210    if (png_ptr == NULL)
    11951211       return;
    1196     if(png_ptr->zbuf)
    1197        png_free(png_ptr, png_ptr->zbuf);
     1212    png_free(png_ptr, png_ptr->zbuf);
    11981213    png_ptr->zbuf_size = (png_size_t)size;
    11991214    png_ptr->zbuf = (png_bytep)png_malloc(png_ptr, size);
    12001215    png_ptr->zstream.next_out = png_ptr->zbuf;
  • src/libs/png/pngrutil.c

     
    11
    22/* pngrutil.c - utilities to read a PNG file
    33 *
    4  * Last changed in libpng 1.2.26 [April 2, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    12411241png_handle_tRNS(png_structp png_ptr, png_infop info_ptr, png_uint_32 length)
    12421242{
    12431243   png_byte readbuf[PNG_MAX_PALETTE_LENGTH];
    1244    int bit_mask;
    12451244
    12461245   png_debug(1, "in png_handle_tRNS\n");
    12471246
    1248    /* For non-indexed color, mask off any bits in the tRNS value that
    1249     * exceed the bit depth.  Some creators were writing extra bits there.
    1250     * This is not needed for indexed color. */
    1251    bit_mask = (1 << png_ptr->bit_depth) - 1;
    1252 
    12531247   if (!(png_ptr->mode & PNG_HAVE_IHDR))
    12541248      png_error(png_ptr, "Missing IHDR before tRNS");
    12551249   else if (png_ptr->mode & PNG_HAVE_IDAT)
     
    12781272
    12791273      png_crc_read(png_ptr, buf, 2);
    12801274      png_ptr->num_trans = 1;
    1281       png_ptr->trans_values.gray = png_get_uint_16(buf) & bit_mask;
     1275      png_ptr->trans_values.gray = png_get_uint_16(buf);
    12821276   }
    12831277   else if (png_ptr->color_type == PNG_COLOR_TYPE_RGB)
    12841278   {
     
    12921286      }
    12931287      png_crc_read(png_ptr, buf, (png_size_t)length);
    12941288      png_ptr->num_trans = 1;
    1295       png_ptr->trans_values.red = png_get_uint_16(buf) & bit_mask;
    1296       png_ptr->trans_values.green = png_get_uint_16(buf + 2) & bit_mask;
    1297       png_ptr->trans_values.blue = png_get_uint_16(buf + 4) & bit_mask;
     1289      png_ptr->trans_values.red = png_get_uint_16(buf);
     1290      png_ptr->trans_values.green = png_get_uint_16(buf + 2);
     1291      png_ptr->trans_values.blue = png_get_uint_16(buf + 4);
    12981292   }
    12991293   else if (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE)
    13001294   {
     
    22272221                  (png_charp)png_ptr->chunk_name,
    22282222                  png_sizeof(png_ptr->unknown_chunk.name));
    22292223       png_ptr->unknown_chunk.name[png_sizeof(png_ptr->unknown_chunk.name)-1] = '\0';
    2230        png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length);
    22312224       png_ptr->unknown_chunk.size = (png_size_t)length;
    2232        png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length);
     2225       if (length == 0)
     2226         png_ptr->unknown_chunk.data = NULL;
     2227       else
     2228       {
     2229         png_ptr->unknown_chunk.data = (png_bytep)png_malloc(png_ptr, length);
     2230         png_crc_read(png_ptr, (png_bytep)png_ptr->unknown_chunk.data, length);
     2231       }
    22332232#if defined(PNG_READ_USER_CHUNKS_SUPPORTED)
    22342233       if(png_ptr->read_user_chunk_fn != NULL)
    22352234       {
     
    22512250       }
    22522251       else
    22532252#endif
    2254          png_set_unknown_chunks(png_ptr, info_ptr, &png_ptr->unknown_chunk, 1);
     2253       png_set_unknown_chunks(png_ptr, info_ptr, &png_ptr->unknown_chunk, 1);
    22552254       png_free(png_ptr, png_ptr->unknown_chunk.data);
    22562255       png_ptr->unknown_chunk.data = NULL;
    22572256   }
     
    31493148
    31503149   if(row_bytes + 64 > png_ptr->old_big_row_buf_size)
    31513150   {
    3152      if (png_ptr->big_row_buf)
    3153         png_free(png_ptr,png_ptr->big_row_buf);
     3151     png_free(png_ptr,png_ptr->big_row_buf);
    31543152     png_ptr->big_row_buf = (png_bytep)png_malloc(png_ptr, row_bytes+64);
    31553153     png_ptr->row_buf = png_ptr->big_row_buf+32;
    31563154     png_ptr->old_big_row_buf_size = row_bytes+64;
     
    31653163
    31663164   if(png_ptr->rowbytes+1 > png_ptr->old_prev_row_size)
    31673165   {
    3168      if (png_ptr->prev_row)
    3169         png_free(png_ptr,png_ptr->prev_row);
     3166     png_free(png_ptr,png_ptr->prev_row);
    31703167     png_ptr->prev_row = (png_bytep)png_malloc(png_ptr, (png_uint_32)(
    31713168        png_ptr->rowbytes + 1));
    31723169     png_ptr->old_prev_row_size = png_ptr->rowbytes+1;
  • src/libs/png/pngwutil.c

     
    11
    22/* pngwutil.c - utilities to write a PNG file
    33 *
    4  * Last changed in libpng 1.2.26 [April 2, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    15161516
    15171517   png_write_chunk_end(png_ptr);
    15181518   png_free(png_ptr, new_key);
    1519    if (new_lang)
    1520      png_free(png_ptr, new_lang);
     1519   png_free(png_ptr, new_lang);
    15211520}
    15221521#endif
    15231522
  • src/libs/png/pngmem.c

     
    11
    22/* pngmem.c - stub functions for memory allocation
    33 *
    4  * Last changed in libpng 1.2.26 [April 2, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    293293{
    294294#endif /* PNG_USER_MEM_SUPPORTED */
    295295
    296    if(png_ptr == NULL) return;
     296   if(png_ptr == NULL || ptr == NULL) return;
    297297
    298298   if (png_ptr->offset_table != NULL)
    299299   {
  • src/libs/png/png.c

     
    1313#include "png.h"
    1414
    1515/* Generate a compiler error if there is an old png.h in the search path. */
    16 typedef version_1_2_26 Your_png_h_is_not_version_1_2_26;
     16typedef version_1_2_29 Your_png_h_is_not_version_1_2_29;
    1717
    1818/* Version information for C files.  This had better match the version
    1919 * string defined in png.h.  */
     
    693693png_get_copyright(png_structp png_ptr)
    694694{
    695695   png_ptr = png_ptr;  /* silence compiler warning about unused png_ptr */
    696    return ((png_charp) "\n libpng version 1.2.26 - April 2, 2008\n\
     696   return ((png_charp) "\n libpng version 1.2.29 - May 8, 2008\n\
    697697   Copyright (c) 1998-2008 Glenn Randers-Pehrson\n\
    698698   Copyright (c) 1996-1997 Andreas Dilger\n\
    699699   Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.\n");
  • src/libs/png/pnggccrd.c

     
    22
    33/* This code snippet is for use by configure's compilation test. */
    44
    5 #if defined(PNG_ASSEMBLER_CODE_SUPPORTED) && \
     5#if (!defined _MSC_VER) && \
     6    defined(PNG_ASSEMBLER_CODE_SUPPORTED) && \
    67    defined(PNG_MMX_CODE_SUPPORTED)
     8
    79int PNGAPI png_dummy_mmx_support(void);
    810
    911static int _mmx_supported = 2; // 0: no MMX; 1: MMX supported; 2: not tested
  • src/libs/png/pngrtran.c

     
    11
    22/* pngrtran.c - transforms the data in a row for PNG readers
    33 *
    4  * Last changed in libpng 1.2.25 [February 18, 2008]
     4 * Last changed in libpng 1.2.27 [April 29, 2008]
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
     
    548548   png_debug(1, "in png_set_expand\n");
    549549   if(png_ptr == NULL) return;
    550550   png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS);
    551 #ifdef PNG_WARN_UNINITIALIZED_ROW
    552551   png_ptr->flags &= ~PNG_FLAG_ROW_INIT;
    553 #endif
    554552}
    555553
    556554/* GRR 19990627:  the following three functions currently are identical
     
    577575   png_debug(1, "in png_set_palette_to_rgb\n");
    578576   if(png_ptr == NULL) return;
    579577   png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS);
    580 #ifdef PNG_WARN_UNINITIALIZED_ROW
    581578   png_ptr->flags &= ~PNG_FLAG_ROW_INIT;
    582 #endif
    583579}
    584580
    585581#if !defined(PNG_1_0_X)
     
    590586   png_debug(1, "in png_set_expand_gray_1_2_4_to_8\n");
    591587   if(png_ptr == NULL) return;
    592588   png_ptr->transformations |= PNG_EXPAND;
    593 #ifdef PNG_WARN_UNINITIALIZED_ROW
    594589   png_ptr->flags &= ~PNG_FLAG_ROW_INIT;
    595 #endif
    596590}
    597591#endif
    598592
     
    615609{
    616610   png_debug(1, "in png_set_tRNS_to_alpha\n");
    617611   png_ptr->transformations |= (PNG_EXPAND | PNG_EXPAND_tRNS);
    618 #ifdef PNG_WARN_UNINITIALIZED_ROW
    619612   png_ptr->flags &= ~PNG_FLAG_ROW_INIT;
    620 #endif
    621613}
    622614#endif /* defined(PNG_READ_EXPAND_SUPPORTED) */
    623615
     
    627619{
    628620   png_debug(1, "in png_set_gray_to_rgb\n");
    629621   png_ptr->transformations |= PNG_GRAY_TO_RGB;
    630 #ifdef PNG_WARN_UNINITIALIZED_ROW
    631622   png_ptr->flags &= ~PNG_FLAG_ROW_INIT;
    632 #endif
    633623}
    634624#endif
    635625
     
    967957        /* Prevent the transformations being done again, and make sure
    968958         * that the now spurious alpha channel is stripped - the code
    969959         * has just reduced background composition and gamma correction
    970          * to a simply alpha channel strip.
     960         * to a simple alpha channel strip.
    971961         */
    972962        png_ptr->transformations &= ~PNG_BACKGROUND;
    973963        png_ptr->transformations &= ~PNG_GAMMA;
     
    11381128   {
    11391129      if (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE)
    11401130      {
    1141          if (png_ptr->num_trans && (png_ptr->transformations & PNG_EXPAND_tRNS))
     1131         if (png_ptr->num_trans &&
     1132              (png_ptr->transformations & PNG_EXPAND_tRNS))
    11421133            info_ptr->color_type = PNG_COLOR_TYPE_RGB_ALPHA;
    11431134         else
    11441135            info_ptr->color_type = PNG_COLOR_TYPE_RGB;
     
    11511142         {
    11521143            if (png_ptr->transformations & PNG_EXPAND_tRNS)
    11531144              info_ptr->color_type |= PNG_COLOR_MASK_ALPHA;
     1145#if 0 /* Removed from libpng-1.2.27 */
    11541146            else
    11551147              info_ptr->color_type |= PNG_COLOR_MASK_COLOR;
     1148#endif
    11561149         }
    11571150         if (info_ptr->bit_depth < 8)
    11581151            info_ptr->bit_depth = 8;
  • headers/libs/png/pngconf.h

     
    11
    22/* pngconf.h - machine configurable file for libpng
    33 *
    4  * libpng version 1.2.26 - April 2, 2008
     4 * libpng version 1.2.29 - May 8, 2008
    55 * For conditions of distribution and use, see copyright notice in png.h
    66 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    77 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
  • headers/libs/png/png.h

     
    1 
    21/* png.h - header file for PNG reference library
    32 *
    4  * libpng version 1.2.26 - April 2, 2008
     3 * libpng version 1.2.29 - May 8, 2008
    54 * Copyright (c) 1998-2008 Glenn Randers-Pehrson
    65 * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
    76 * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
     
    98 * Authors and maintainers:
    109 *  libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat
    1110 *  libpng versions 0.89c, June 1996, through 0.96, May 1997: Andreas Dilger
    12  *  libpng versions 0.97, January 1998, through 1.2.26 - April 2, 2008: Glenn
     11 *  libpng versions 0.97, January 1998, through 1.2.29 - May 8, 2008: Glenn
    1312 *  See also "Contributing Authors", below.
    1413 *
    1514 * Note about libpng version numbers:
     
    181180 *    1.2.25                  13    10225  12.so.0.25[.0]
    182181 *    1.2.26beta01-06         13    10226  12.so.0.26[.0]
    183182 *    1.2.26rc01              13    10226  12.so.0.26[.0]
     183 *    1.2.26                  13    10226  12.so.0.26[.0]
     184 *    1.0.32                  10    10032  10.so.0.32[.0]
     185 *    1.2.27beta01-06         13    10227  12.so.0.27[.0]
     186 *    1.2.27rc01              13    10227  12.so.0.27[.0]
     187 *    1.0.33                  10    10033  10.so.0.33[.0]
     188 *    1.2.27                  13    10227  12.so.0.27[.0]
     189 *    1.0.34                  10    10034  10.so.0.34[.0]
     190 *    1.2.28                  13    10228  12.so.0.28[.0]
     191 *    1.2.29beta01-03         13    10229  12.so.0.29[.0]
     192 *    1.2.29rc01              13    10229  12.so.0.29[.0]
     193 *    1.0.35                  10    10035  10.so.0.35[.0]
     194 *    1.2.29                  13    10229  12.so.0.29[.0]
    184195 *
    185196 *    Henceforth the source version will match the shared-library major
    186197 *    and minor numbers; the shared-library major version number will be
     
    190201 *    to the source version x.y.z (leading zeros in y and z).  Beta versions
    191202 *    were given the previous public release number plus a letter, until
    192203 *    version 1.0.6j; from then on they were given the upcoming public
    193  *    release number plus "betaNN" or "rcN".
     204 *    release number plus "betaNN" or "rcNN".
    194205 *
    195206 *    Binary incompatibility exists only when applications make direct access
    196207 *    to the info_ptr or png_ptr members through png.h, and the compiled
     
    210221 * If you modify libpng you may insert additional notices immediately following
    211222 * this sentence.
    212223 *
    213  * libpng versions 1.2.6, August 15, 2004, through 1.2.26, April 2, 2008, are
     224 * libpng versions 1.2.6, August 15, 2004, through 1.2.29, May 8, 2008, are
    214225 * Copyright (c) 2004, 2006-2008 Glenn Randers-Pehrson, and are
    215226 * distributed according to the same disclaimer and license as libpng-1.2.5
    216227 * with the following individual added to the list of Contributing Authors:
     
    322333 * Y2K compliance in libpng:
    323334 * =========================
    324335 *
    325  *    April 2, 2008
     336 *    May 8, 2008
    326337 *
    327338 *    Since the PNG Development group is an ad-hoc body, we can't make
    328339 *    an official declaration.
    329340 *
    330341 *    This is your unofficial assurance that libpng from version 0.71 and
    331  *    upward through 1.2.26 are Y2K compliant.  It is my belief that earlier
     342 *    upward through 1.2.29 are Y2K compliant.  It is my belief that earlier
    332343 *    versions were also Y2K compliant.
    333344 *
    334345 *    Libpng only has three year fields.  One is a 2-byte unsigned integer
     
    384395 */
    385396
    386397/* Version information for png.h - this should match the version in png.c */
    387 #define PNG_LIBPNG_VER_STRING "1.2.26"
     398#define PNG_LIBPNG_VER_STRING "1.2.29"
    388399#define PNG_HEADER_VERSION_STRING \
    389    " libpng version 1.2.26 - April 2, 2008\n"
     400   " libpng version 1.2.29 - May 8, 2008\n"
    390401
    391402#define PNG_LIBPNG_VER_SONUM   0
    392403#define PNG_LIBPNG_VER_DLLNUM  13
     
    394405/* These should match the first 3 components of PNG_LIBPNG_VER_STRING: */
    395406#define PNG_LIBPNG_VER_MAJOR   1
    396407#define PNG_LIBPNG_VER_MINOR   2
    397 #define PNG_LIBPNG_VER_RELEASE 26
     408#define PNG_LIBPNG_VER_RELEASE 29
    398409/* This should match the numeric part of the final component of
    399410 * PNG_LIBPNG_VER_STRING, omitting any leading zero: */
    400411
     
    422433 * Versions 0.7 through 1.0.0 were in the range 0 to 100 here (only
    423434 * version 1.0.0 was mis-numbered 100 instead of 10000).  From
    424435 * version 1.0.1 it's    xxyyzz, where x=major, y=minor, z=release */
    425 #define PNG_LIBPNG_VER 10226 /* 1.2.26 */
     436#define PNG_LIBPNG_VER 10229 /* 1.2.29 */
    426437
    427438#ifndef PNG_VERSION_INFO_ONLY
    428439/* include the compression library's header */
     
    14391450/* This triggers a compiler error in png.c, if png.c and png.h
    14401451 * do not agree upon the version number.
    14411452 */
    1442 typedef png_structp version_1_2_26;
     1453typedef png_structp version_1_2_29;
    14431454
    14441455typedef png_struct FAR * FAR * png_structpp;
    14451456