[libpng16] Fix typos in comments in pngset.c and pngtrans.c

This commit is contained in:
Glenn Randers-Pehrson 2014-10-03 20:23:31 -05:00
parent ca9c3a601b
commit 9127138a30
3 changed files with 8 additions and 8 deletions

View File

@ -726,7 +726,7 @@ png_set_text_2(png_const_structrp png_ptr, png_inforp info_ptr,
else else
max_text = INT_MAX; max_text = INT_MAX;
/* Now allocate a new array and copy the old members in, this does all /* Now allocate a new array and copy the old members in; this does all
* the overflow checks. * the overflow checks.
*/ */
new_text = png_voidcast(png_textp,png_realloc_array(png_ptr, new_text = png_voidcast(png_textp,png_realloc_array(png_ptr,
@ -1020,8 +1020,8 @@ png_set_sPLT(png_const_structrp png_ptr,
np->depth = entries->depth; np->depth = entries->depth;
/* In the even of out-of-memory just return - there's no point keeping on /* In the event of out-of-memory just return - there's no point keeping
* trying to add sPLT chunks. * on trying to add sPLT chunks.
*/ */
length = strlen(entries->name) + 1; length = strlen(entries->name) + 1;
np->name = png_voidcast(png_charp, png_malloc_base(png_ptr, length)); np->name = png_voidcast(png_charp, png_malloc_base(png_ptr, length));
@ -1032,8 +1032,8 @@ png_set_sPLT(png_const_structrp png_ptr,
memcpy(np->name, entries->name, length); memcpy(np->name, entries->name, length);
/* IMPORTANT: we have memory now that won't get freed if something else /* IMPORTANT: we have memory now that won't get freed if something else
* goes wrong, this code must free it. png_malloc_array produces no * goes wrong; this code must free it. png_malloc_array produces no
* warnings, use a png_chunk_report (below) if there is an error. * warnings; use a png_chunk_report (below) if there is an error.
*/ */
np->entries = png_voidcast(png_sPLT_entryp, png_malloc_array(png_ptr, np->entries = png_voidcast(png_sPLT_entryp, png_malloc_array(png_ptr,
entries->nentries, sizeof (png_sPLT_entry))); entries->nentries, sizeof (png_sPLT_entry)));
@ -1072,7 +1072,7 @@ check_location(png_const_structrp png_ptr, int location)
location &= (PNG_HAVE_IHDR|PNG_HAVE_PLTE|PNG_AFTER_IDAT); location &= (PNG_HAVE_IHDR|PNG_HAVE_PLTE|PNG_AFTER_IDAT);
/* New in 1.6.0; copy the location and check it. This is an API /* New in 1.6.0; copy the location and check it. This is an API
* change, previously the app had to use the * change; previously the app had to use the
* png_set_unknown_chunk_location API below for each chunk. * png_set_unknown_chunk_location API below for each chunk.
*/ */
if (location == 0 && !(png_ptr->mode & PNG_IS_READ_STRUCT)) if (location == 0 && !(png_ptr->mode & PNG_IS_READ_STRUCT))

View File

@ -828,7 +828,7 @@ png_get_user_transform_ptr(png_const_structrp png_ptr)
png_uint_32 PNGAPI png_uint_32 PNGAPI
png_get_current_row_number(png_const_structrp png_ptr) png_get_current_row_number(png_const_structrp png_ptr)
{ {
/* See the comments in png.h - this is the sub-image row when reading and /* See the comments in png.h - this is the sub-image row when reading an
* interlaced image. * interlaced image.
*/ */
if (png_ptr != NULL) if (png_ptr != NULL)

View File

@ -1,7 +1,7 @@
/* pngwio.c - functions for data output /* pngwio.c - functions for data output
* *
* Last changed in libpng 1.6.14 [(PENDING RELEASE)] * Last changed in libpng 1.6.9 [February 6, 2014]
* Copyright (c) 1998-2014 Glenn Randers-Pehrson * Copyright (c) 1998-2014 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)