[arch-commits] Commit in thunderbird/trunk (libpng15.patch)
Ionut Biru
ibiru at archlinux.org
Tue Jan 31 19:34:05 UTC 2012
Date: Tuesday, January 31, 2012 @ 14:34:04
Author: ibiru
Revision: 148427
not needed
Deleted:
thunderbird/trunk/libpng15.patch
----------------+
libpng15.patch | 52 ----------------------------------------------------
1 file changed, 52 deletions(-)
Deleted: libpng15.patch
===================================================================
--- libpng15.patch 2012-01-31 19:28:25 UTC (rev 148426)
+++ libpng15.patch 2012-01-31 19:34:04 UTC (rev 148427)
@@ -1,52 +0,0 @@
-diff -Nur comm-release.orig/mozilla/modules/libpr0n/decoders/nsICODecoder.cpp comm-release/mozilla/modules/libpr0n/decoders/nsICODecoder.cpp
---- comm-release.orig/mozilla/modules/libpr0n/decoders/nsICODecoder.cpp 2012-01-29 19:29:28.121217854 +0000
-+++ comm-release/mozilla/modules/libpr0n/decoders/nsICODecoder.cpp 2012-01-29 19:32:05.489944419 +0000
-@@ -385,8 +385,7 @@
-
- // Raymond Chen says that 32bpp only are valid PNG ICOs
- // http://blogs.msdn.com/b/oldnewthing/archive/2010/10/22/10079192.aspx
-- if (static_cast<nsPNGDecoder*>(mContainedDecoder.get())->HasValidInfo() &&
-- static_cast<nsPNGDecoder*>(mContainedDecoder.get())->GetPixelDepth() != 32) {
-+ if (!static_cast<nsPNGDecoder*>(mContainedDecoder.get())->IsValidICO()) {
- PostDataError();
- }
- return;
-diff -Nur comm-release.orig/mozilla/modules/libpr0n/decoders/nsPNGDecoder.h comm-release/mozilla/modules/libpr0n/decoders/nsPNGDecoder.h
---- comm-release.orig/mozilla/modules/libpr0n/decoders/nsPNGDecoder.h 2012-01-29 19:29:28.121217854 +0000
-+++ comm-release/mozilla/modules/libpr0n/decoders/nsPNGDecoder.h 2012-01-29 19:32:05.489944419 +0000
-@@ -73,19 +73,25 @@
-
- void EndImageFrame();
-
-- // Checks if the info header contains valid information
-- bool HasValidInfo() const
-+ // Check if PNG is valid ICO (32bpp RGBA)
-+ // http://blogs.msdn.com/b/oldnewthing/archive/2010/10/22/10079192.aspx
-+ bool IsValidICO() const
- {
-- return mInfo && mInfo->valid;
-- }
-+ png_uint_32
-+ png_width, // Unused
-+ png_height; // Unused
-
-- // Obtain the pixel depth if available or 0 otherwise
-- PRInt32 GetPixelDepth() const
-- {
-- if (!mInfo) {
-- return 0;
-+ int png_bit_depth,
-+ png_color_type;
-+
-+ if (png_get_IHDR(mPNG, mInfo, &png_width, &png_height, &png_bit_depth,
-+ &png_color_type, NULL, NULL, NULL)) {
-+
-+ return (png_color_type == PNG_COLOR_TYPE_RGB_ALPHA &&
-+ png_bit_depth == 8);
-+ } else {
-+ return false;
- }
-- return mInfo->pixel_depth;
- }
-
- public:
More information about the arch-commits
mailing list