diff options
author | Glenn Randers-Pehrson <glennrp at users.sourceforge.net> | 2010-03-09 22:28:33 -0600 |
---|---|---|
committer | Glenn Randers-Pehrson <glennrp at users.sourceforge.net> | 2010-03-09 22:28:33 -0600 |
commit | 632a84eff7a52bcdf60d6c5dbc4f1677f289e34e (patch) | |
tree | 687588edbc0bf13b7a53366f43a1ecf7f9304ffb /pngrutil.c | |
parent | 31f92b0ffa1f472f049af7a6207867d786004d5a (diff) | |
download | libpng-632a84eff7a52bcdf60d6c5dbc4f1677f289e34e.tar.gz |
[devel] Make all png_debug macros into *unterminated* statements
or expressions (i.e. a trailing ';' must always be added) and correct
the format statements in various png_debug messages.
Diffstat (limited to 'pngrutil.c')
-rw-r--r-- | pngrutil.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/pngrutil.c b/pngrutil.c index 3f891bdc8..6016a2bfb 100644 --- a/pngrutil.c +++ b/pngrutil.c @@ -1,7 +1,7 @@ /* pngrutil.c - utilities to read a PNG file * - * Last changed in libpng 1.4.1 [March 9, 2010] + * Last changed in libpng 1.4.1 [March 10, 2010] * Copyright (c) 1998-2010 Glenn Randers-Pehrson * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.) @@ -89,7 +89,7 @@ png_read_chunk_header(png_structp png_ptr) /* Put the chunk name into png_ptr->chunk_name */ png_memcpy(png_ptr->chunk_name, buf + 4, 4); - png_debug2(0, "Reading %s chunk, length = %lu", + png_debug2(0, "Reading %s chunk, length = %u", png_ptr->chunk_name, length); /* Reset the crc and run it over the chunk name */ @@ -481,7 +481,7 @@ png_handle_IHDR(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) png_ptr->rowbytes = PNG_ROWBYTES(png_ptr->pixel_depth, png_ptr->width); png_debug1(3, "bit_depth = %d", png_ptr->bit_depth); png_debug1(3, "channels = %d", png_ptr->channels); - png_debug1(3, "rowbytes = %lu", png_ptr->rowbytes); + png_debug1(3, "rowbytes = %u", png_ptr->rowbytes); png_set_IHDR(png_ptr, info_ptr, width, height, bit_depth, color_type, interlace_type, compression_type, filter_type); } @@ -1669,7 +1669,7 @@ png_handle_pCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } - png_debug1(2, "Allocating and reading pCAL chunk data (%lu bytes)", + png_debug1(2, "Allocating and reading pCAL chunk data (%u bytes)", length + 1); png_free(png_ptr, png_ptr->chunkdata); png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); @@ -1809,7 +1809,7 @@ png_handle_sCAL(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) return; } - png_debug1(2, "Allocating and reading sCAL chunk data (%lu bytes)", + png_debug1(2, "Allocating and reading sCAL chunk data (%u bytes)", length + 1); png_ptr->chunkdata = (png_charp)png_malloc_warn(png_ptr, length + 1); if (png_ptr->chunkdata == NULL) @@ -2909,7 +2909,7 @@ png_read_filter_row(png_structp png_ptr, png_row_infop row_info, png_bytep row, png_bytep prev_row, int filter) { png_debug(1, "in png_read_filter_row"); - png_debug2(2, "row = %lu, filter = %d", png_ptr->row_number, filter); + png_debug2(2, "row = %u, filter = %d", png_ptr->row_number, filter); switch (filter) { case PNG_FILTER_VALUE_NONE: @@ -3357,12 +3357,12 @@ defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) png_memset(png_ptr->prev_row, 0, png_ptr->rowbytes + 1); - png_debug1(3, "width = %lu,", png_ptr->width); - png_debug1(3, "height = %lu,", png_ptr->height); - png_debug1(3, "iwidth = %lu,", png_ptr->iwidth); - png_debug1(3, "num_rows = %lu,", png_ptr->num_rows); - png_debug1(3, "rowbytes = %lu,", png_ptr->rowbytes); - png_debug1(3, "irowbytes = %lu", + png_debug1(3, "width = %u,", png_ptr->width); + png_debug1(3, "height = %u,", png_ptr->height); + png_debug1(3, "iwidth = %u,", png_ptr->iwidth); + png_debug1(3, "num_rows = %u,", png_ptr->num_rows); + png_debug1(3, "rowbytes = %u,", png_ptr->rowbytes); + png_debug1(3, "irowbytes = %u", PNG_ROWBYTES(png_ptr->pixel_depth, png_ptr->iwidth) + 1); png_ptr->flags |= PNG_FLAG_ROW_INIT; |