--- libs/auxfun/image.cpp.libpng 2011-12-12 06:34:26.206375553 +0800 +++ libs/auxfun/image.cpp 2011-12-12 06:38:12.626375893 +0800 @@ -94,7 +94,7 @@ png_init_io (png, file); - if (setjmp (png->jmpbuf)) + if (setjmp (png_jmpbuf(png))) // If we get here, we had a problem reading the file goto nomem; @@ -157,7 +157,7 @@ row_pointers = new png_bytep [Height]; if (!row_pointers - || setjmp (png->jmpbuf)) // Set a new exception handler + || setjmp (png_jmpbuf(png))) // Set a new exception handler { delete [] row_pointers; nomem: @@ -214,7 +214,7 @@ } /* Catch processing errors */ - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) /* If we get here, we had a problem writing the file */ goto error2; @@ -273,10 +273,6 @@ /* It is REQUIRED to call this to finish writing the rest of the file */ png_write_end (png, info); - /* if you malloced the palette, free it here */ - if (info->palette) - free (info->palette); - /* clean up after the write, and free any memory allocated */ png_destroy_write_struct (&png, &info);