summaryrefslogtreecommitdiff
path: root/third_party/libpng16
diff options
context:
space:
mode:
authorOliver Chang <ochang@chromium.org>2016-01-19 14:34:25 -0800
committerOliver Chang <ochang@chromium.org>2016-01-19 14:34:25 -0800
commitfd5f130ac81537c9066f5fb7998fdf08f501b40e (patch)
treeb8cd3093b244a426d541005a7378777e62906747 /third_party/libpng16
parentdc4d504f78e65156a680ae995e3215c258b48e87 (diff)
downloadpdfium-fd5f130ac81537c9066f5fb7998fdf08f501b40e.tar.xz
XFA: Unconditionally use static png_gt() in png.c
This is to avoid a compilation warning. R=thakis@chromium.org TBR=thestig@chromium.org Review URL: https://codereview.chromium.org/1607053003 .
Diffstat (limited to 'third_party/libpng16')
-rw-r--r--third_party/libpng16/0002-static-png-gt.patch14
-rw-r--r--third_party/libpng16/README.pdfium1
-rw-r--r--third_party/libpng16/png.c3
3 files changed, 17 insertions, 1 deletions
diff --git a/third_party/libpng16/0002-static-png-gt.patch b/third_party/libpng16/0002-static-png-gt.patch
new file mode 100644
index 0000000000..b2b1d94971
--- /dev/null
+++ b/third_party/libpng16/0002-static-png-gt.patch
@@ -0,0 +1,14 @@
+diff --git a/third_party/libpng16/png.c b/third_party/libpng16/png.c
+index c183e3f..1cf5271 100644
+--- a/third_party/libpng16/png.c
++++ b/third_party/libpng16/png.c
+@@ -2464,7 +2464,8 @@ png_colorspace_set_rgb_coefficients(png_structrp png_ptr)
+
+ #endif /* COLORSPACE */
+
+-#ifdef __GNUC__
++/* #ifdef __GNUC__ */
++#if 1
+ /* This exists solely to work round a warning from GNU C. */
+ static int /* PRIVATE */
+ png_gt(size_t a, size_t b)
diff --git a/third_party/libpng16/README.pdfium b/third_party/libpng16/README.pdfium
index 66d2d0684a..d60bc6f428 100644
--- a/third_party/libpng16/README.pdfium
+++ b/third_party/libpng16/README.pdfium
@@ -12,3 +12,4 @@ Local Modifications:
pnglibconf.h: a copy of libpng's scripts/pnglibconf.h.prebuilt.
0000-build-config.patch: Local build configuration changes.
0001-disable-arm-neon.diff: Disable ARM NEON optimizations.
+0002-static-png-gt.patch: Unconditionally use static png_gt() in png.c to avoid compilation warning.
diff --git a/third_party/libpng16/png.c b/third_party/libpng16/png.c
index c183e3f8fa..1cf5271046 100644
--- a/third_party/libpng16/png.c
+++ b/third_party/libpng16/png.c
@@ -2464,7 +2464,8 @@ png_colorspace_set_rgb_coefficients(png_structrp png_ptr)
#endif /* COLORSPACE */
-#ifdef __GNUC__
+/* #ifdef __GNUC__ */
+#if 1
/* This exists solely to work round a warning from GNU C. */
static int /* PRIVATE */
png_gt(size_t a, size_t b)