[devel] Added some "(unsigned int)" typecasts in pngvalid.c printf statements.

This commit is contained in:
Glenn Randers-Pehrson
2010-10-08 13:35:02 -05:00
parent 4f5b846bb4
commit e9c395a3bf
3 changed files with 10 additions and 5 deletions

View File

@@ -821,7 +821,8 @@ store_pool_delete(png_store *ps, store_pool *pool)
pool->list = next->next;
next->next = NULL;
fprintf(stderr, "\t%ud bytes @ %p\n", next->size, next+1);
fprintf(stderr, "\t%ud bytes @ %p\n",
(unsigned int)next->size, next+1);
/* The NULL means this will always return, even if the memory is
* corrupted.
*/
@@ -3652,10 +3653,12 @@ int main(int argc, PNG_CONST char **argv)
printf("Allocated memory statistics (in bytes):\n"
"\tread %u maximum single, %u peak, %u total\n"
"\twrite %u maximum single, %u peak, %u total\n",
pm.this.read_memory_pool.max_max, pm.this.read_memory_pool.max_limit,
pm.this.read_memory_pool.max_total, pm.this.write_memory_pool.max_max,
pm.this.write_memory_pool.max_limit,
pm.this.write_memory_pool.max_total);
(unsigned int)pm.this.read_memory_pool.max_max,
(unsigned int)pm.this.read_memory_pool.max_limit,
(unsigned int)pm.this.read_memory_pool.max_total,
(unsigned int)pm.this.write_memory_pool.max_max,
(unsigned int)pm.this.write_memory_pool.max_limit,
(unsigned int)pm.this.write_memory_pool.max_total);
}
/* Do this here to provoke memory corruption errors in memory not directly