提交 92d0fe93 编写于 作者: G Glenn Randers-Pehrson

Add PNG_SKIP_SETJMP_CHECK macro

上级 d07e9b03
......@@ -86,7 +86,9 @@ version 1.2.36beta04 [April 5, 2009]
Fixed potential memory leak of "new_name" in png_write_iCCP() (Ralph Giles)
version 1.2.36beta05 [April 13, 2009]
None.
Added "ifndef PNG_SKIP_SETJMP_CHECK" block in pngconf.h to allow
application code writers to bypass the check for multiple inclusion
of setjmp.h when they know that it is safe to ignore the situation.
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
......
......@@ -2353,7 +2353,10 @@ version 1.2.36beta04 [April 5, 2009]
Fixed potential memory leak of "new_name" in png_write_iCCP() (Ralph Giles)
version 1.2.36beta05 [April 13, 2009]
None.
Added "ifndef PNG_SKIP_SETJMP_CHECK" block in pngconf.h to allow
application code writers to bypass the check for multiple inclusion
of setjmp.h when they know that it is safe to ignore the situation.
Made some cosmetic changes to whitespace in pngtest output.
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
(subscription required; visit
......
......@@ -314,21 +314,29 @@
#ifdef PNG_SETJMP_SUPPORTED
/* This is an attempt to force a single setjmp behaviour on Linux. If
* the X config stuff didn't define _BSD_SOURCE we wouldn't need this.
*
* You can bypass this test if you know that your application uses exactly
* the same setjmp.h that was included when libpng was built. Only define
* PNG_SKIP_SETJMP_CHECK while building your application, prior to the
* application's '#include "png.h"'. Don't define PNG_SKIP_SETJMP_CHECK
* while building a separate libpng library for general use.
*/
# ifdef __linux__
# ifdef _BSD_SOURCE
# define PNG_SAVE_BSD_SOURCE
# undef _BSD_SOURCE
# endif
# ifdef _SETJMP_H
/* If you encounter a compiler error here, see the explanation
* near the end of INSTALL.
*/
__pngconf.h__ already includes setjmp.h;
__dont__ include it again.;
# endif
# endif /* __linux__ */
# ifndef PNG_SKIP_SETJMP_CHECK
# ifdef __linux__
# ifdef _BSD_SOURCE
# define PNG_SAVE_BSD_SOURCE
# undef _BSD_SOURCE
# endif
# ifdef _SETJMP_H
/* If you encounter a compiler error here, see the explanation
* near the end of INSTALL.
*/
__pngconf.h__ in libpng already includes setjmp.h;
__dont__ include it again.;
# endif
# endif /* __linux__ */
# endif /* PNG_SKIP_SETJMP_CHECK */
/* include setjmp.h for error handling */
# include <setjmp.h>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册