mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[devel] Imported from libpng-1.5.0beta09.tar
This commit is contained in:
10
pngread.c
10
pngread.c
@@ -50,7 +50,7 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr,
|
||||
|
||||
#ifdef PNG_SETJMP_SUPPORTED
|
||||
#ifdef USE_FAR_KEYWORD
|
||||
jmp_buf jmpbuf;
|
||||
jmp_buf png_jmpbuf;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -86,13 +86,13 @@ png_create_read_struct_2(png_const_charp user_png_ver, png_voidp error_ptr,
|
||||
encounter a png_error() will longjmp here. Since the jmpbuf is
|
||||
then meaningless we abort instead of returning. */
|
||||
#ifdef USE_FAR_KEYWORD
|
||||
if (setjmp(jmpbuf))
|
||||
if (setjmp(png_jmpbuf))
|
||||
#else
|
||||
if (setjmp(png_jmpbuf(png_ptr))) /* Sets longjmp to match setjmp */
|
||||
#endif
|
||||
PNG_ABORT();
|
||||
#ifdef USE_FAR_KEYWORD
|
||||
png_memcpy(png_jmpbuf(png_ptr), jmpbuf, png_sizeof(jmp_buf));
|
||||
png_memcpy(png_jmpbuf(png_ptr), png_jmpbuf, png_sizeof(jmp_buf));
|
||||
#endif
|
||||
#endif /* PNG_SETJMP_SUPPORTED */
|
||||
|
||||
@@ -1159,7 +1159,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr,
|
||||
* being used again.
|
||||
*/
|
||||
#ifdef PNG_SETJMP_SUPPORTED
|
||||
png_memcpy(tmp_jmp, png_ptr->jmpbuf, png_sizeof(jmp_buf));
|
||||
png_memcpy(tmp_jmp, png_ptr->png_jmpbuf, png_sizeof(jmp_buf));
|
||||
#endif
|
||||
|
||||
error_fn = png_ptr->error_fn;
|
||||
@@ -1179,7 +1179,7 @@ png_read_destroy(png_structp png_ptr, png_infop info_ptr,
|
||||
#endif
|
||||
|
||||
#ifdef PNG_SETJMP_SUPPORTED
|
||||
png_memcpy(png_ptr->jmpbuf, tmp_jmp, png_sizeof(jmp_buf));
|
||||
png_memcpy(png_ptr->png_jmpbuf, tmp_jmp, png_sizeof(jmp_buf));
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user