diff options
Diffstat (limited to 'plugins/AdvaImg/src/LibPNG/pngerror.c')
-rw-r--r-- | plugins/AdvaImg/src/LibPNG/pngerror.c | 40 |
1 files changed, 33 insertions, 7 deletions
diff --git a/plugins/AdvaImg/src/LibPNG/pngerror.c b/plugins/AdvaImg/src/LibPNG/pngerror.c index c71e2ab559..7e155cf2d3 100644 --- a/plugins/AdvaImg/src/LibPNG/pngerror.c +++ b/plugins/AdvaImg/src/LibPNG/pngerror.c @@ -1,8 +1,8 @@ /* pngerror.c - stub functions for i/o and memory allocation
*
- * Last changed in libpng 1.6.1 [March 28, 2013]
- * Copyright (c) 1998-2013 Glenn Randers-Pehrson
+ * Last changed in libpng 1.6.10 [March 6, 2014]
+ * Copyright (c) 1998-2014 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -382,6 +382,10 @@ png_benign_error(png_const_structrp png_ptr, png_const_charp error_message) # endif
png_error(png_ptr, error_message);
}
+
+# ifndef PNG_ERROR_TEXT_SUPPORTED
+ PNG_UNUSED(error_message)
+# endif
}
void /* PRIVATE */
@@ -391,6 +395,10 @@ png_app_warning(png_const_structrp png_ptr, png_const_charp error_message) png_warning(png_ptr, error_message);
else
png_error(png_ptr, error_message);
+
+# ifndef PNG_ERROR_TEXT_SUPPORTED
+ PNG_UNUSED(error_message)
+# endif
}
void /* PRIVATE */
@@ -400,6 +408,10 @@ png_app_error(png_const_structrp png_ptr, png_const_charp error_message) png_warning(png_ptr, error_message);
else
png_error(png_ptr, error_message);
+
+# ifndef PNG_ERROR_TEXT_SUPPORTED
+ PNG_UNUSED(error_message)
+# endif
}
#endif /* BENIGN_ERRORS */
@@ -416,7 +428,8 @@ static PNG_CONST char png_digit[16] = { };
#define PNG_MAX_ERROR_TEXT 196 /* Currently limited be profile_error in png.c */
-#if defined(PNG_WARNINGS_SUPPORTED) || defined(PNG_ERROR_TEXT_SUPPORTED)
+#if defined(PNG_WARNINGS_SUPPORTED) || \
+ (defined(PNG_READ_SUPPORTED) && defined(PNG_ERROR_TEXT_SUPPORTED))
static void /* PRIVATE */
png_format_buffer(png_const_structrp png_ptr, png_charp buffer, png_const_charp
error_message)
@@ -506,6 +519,10 @@ png_chunk_benign_error(png_const_structrp png_ptr, png_const_charp else
png_chunk_error(png_ptr, error_message);
+
+# ifndef PNG_ERROR_TEXT_SUPPORTED
+ PNG_UNUSED(error_message)
+# endif
}
#endif
#endif /* PNG_READ_SUPPORTED */
@@ -513,6 +530,10 @@ png_chunk_benign_error(png_const_structrp png_ptr, png_const_charp void /* PRIVATE */
png_chunk_report(png_const_structrp png_ptr, png_const_charp message, int error)
{
+# ifndef PNG_WARNINGS_SUPPORTED
+ PNG_UNUSED(message)
+# endif
+
/* This is always supported, but for just read or just write it
* unconditionally does the right thing.
*/
@@ -740,7 +761,12 @@ png_longjmp,(png_const_structrp png_ptr, int val),PNG_NORETURN) png_ptr->longjmp_fn(*png_ptr->jmp_buf_ptr, val);
#endif
- /* Here if not setjmp support or if png_ptr is null. */
+ /* If control reaches this point, png_longjmp() must not return. The only
+ * choice is to terminate the whole process (or maybe the thread); to do
+ * this the ANSI-C abort() function is used unless a different method is
+ * implemented by overriding the default configuration setting for
+ * PNG_ABORT().
+ */
PNG_ABORT();
}
@@ -850,8 +876,8 @@ png_set_strip_error_numbers(png_structrp png_ptr, png_uint_32 strip_mode) * possible to implement without setjmp support just so long as there is some
* way to handle the error return here:
*/
-PNG_FUNCTION(void /* PRIVATE */,
-png_safe_error,(png_structp png_nonconst_ptr, png_const_charp error_message),
+PNG_FUNCTION(void /* PRIVATE */, (PNGCBAPI
+png_safe_error),(png_structp png_nonconst_ptr, png_const_charp error_message),
PNG_NORETURN)
{
const png_const_structrp png_ptr = png_nonconst_ptr;
@@ -886,7 +912,7 @@ png_safe_error,(png_structp png_nonconst_ptr, png_const_charp error_message), }
#ifdef PNG_WARNINGS_SUPPORTED
-void /* PRIVATE */
+void /* PRIVATE */ PNGCBAPI
png_safe_warning(png_structp png_nonconst_ptr, png_const_charp warning_message)
{
const png_const_structrp png_ptr = png_nonconst_ptr;
|