Lines 70-76
Link Here
|
70 |
static void my_png_error(png_structp png_ptr, png_const_charp msg) |
70 |
static void my_png_error(png_structp png_ptr, png_const_charp msg) |
71 |
{ |
71 |
{ |
72 |
R_ShowMessage((char *) msg); |
72 |
R_ShowMessage((char *) msg); |
73 |
longjmp(png_ptr->jmpbuf,1); |
73 |
longjmp(png_jmpbuf(png_ptr),1); |
74 |
} |
74 |
} |
75 |
|
75 |
|
76 |
static void my_png_warning(png_structp png_ptr, png_const_charp msg) |
76 |
static void my_png_warning(png_structp png_ptr, png_const_charp msg) |
Lines 124-130
Link Here
|
124 |
/* Set error handling. REQUIRED if you aren't supplying your own |
124 |
/* Set error handling. REQUIRED if you aren't supplying your own |
125 |
* error handling functions in the png_create_write_struct() call. |
125 |
* error handling functions in the png_create_write_struct() call. |
126 |
*/ |
126 |
*/ |
127 |
if (setjmp(png_ptr->jmpbuf)) { |
127 |
if (setjmp(png_jmpbuf(png_ptr))) { |
128 |
/* If we get here, we had a problem writing the file */ |
128 |
/* If we get here, we had a problem writing the file */ |
129 |
free(scanline); |
129 |
free(scanline); |
130 |
png_destroy_write_struct(&png_ptr, &info_ptr); |
130 |
png_destroy_write_struct(&png_ptr, &info_ptr); |