Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package ghc-JuicyPixels for openSUSE:Factory 
checked in at 2021-11-11 21:36:04
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-JuicyPixels (Old)
 and      /work/SRC/openSUSE:Factory/.ghc-JuicyPixels.new.1890 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ghc-JuicyPixels"

Thu Nov 11 21:36:04 2021 rev:31 rq:930298 version:3.3.6

Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-JuicyPixels/ghc-JuicyPixels.changes  
2020-12-22 11:33:46.929156968 +0100
+++ 
/work/SRC/openSUSE:Factory/.ghc-JuicyPixels.new.1890/ghc-JuicyPixels.changes    
    2021-11-11 21:36:06.284874769 +0100
@@ -1,0 +2,12 @@
+Wed Oct 13 19:06:54 UTC 2021 - [email protected]
+
+- Update JuicyPixels to version 3.3.6.
+  v3.3.6 October 2021
+  -------------------
+
+   * Bytestring bound bump
+   * Fix bug #187.  (Some JPEGs are misidentified as SourceTiff.)
+   * Fix EXIF handling of strings of four characters or fewer.
+   * Fix endianness bug in short ExifString and ExifUndefined.
+
+-------------------------------------------------------------------

Old:
----
  JuicyPixels-3.3.5.tar.gz

New:
----
  JuicyPixels-3.3.6.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ghc-JuicyPixels.spec ++++++
--- /var/tmp/diff_new_pack.jZdrJv/_old  2021-11-11 21:36:06.756875113 +0100
+++ /var/tmp/diff_new_pack.jZdrJv/_new  2021-11-11 21:36:06.756875113 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package ghc-JuicyPixels
 #
-# Copyright (c) 2020 SUSE LLC
+# Copyright (c) 2021 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -18,7 +18,7 @@
 
 %global pkg_name JuicyPixels
 Name:           ghc-%{pkg_name}
-Version:        3.3.5
+Version:        3.3.6
 Release:        0
 Summary:        Picture loading/serialization (in png, jpeg, bitmap, gif, tga, 
tiff and radiance)
 License:        BSD-3-Clause

++++++ JuicyPixels-3.3.5.tar.gz -> JuicyPixels-3.3.6.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JuicyPixels-3.3.5/JuicyPixels.cabal 
new/JuicyPixels-3.3.6/JuicyPixels.cabal
--- old/JuicyPixels-3.3.5/JuicyPixels.cabal     2020-02-28 09:16:46.000000000 
+0100
+++ new/JuicyPixels-3.3.6/JuicyPixels.cabal     2021-10-13 14:18:38.000000000 
+0200
@@ -1,5 +1,5 @@
 Name:                JuicyPixels
-Version:             3.3.5
+Version:             3.3.6
 Synopsis:            Picture loading/serialization (in png, jpeg, bitmap, gif, 
tga, tiff and radiance)
 Description:
     
<<data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMAAAADABAMAAACg8nE0AAAAElBMVEUAAABJqDSTWEL/qyb///8AAABH/1GTAAAAAXRSTlMAQObYZgAAAN5JREFUeF7s1sEJgFAQxFBbsAV72v5bEVYWPwT/XDxmCsi7zvHXavYREBDI3XP2GgICqBBYuwIC+/rVayPUAyAg0HvIXBcQoDFDGnUBgWQQ2Bx3AYFaRoBpAQHWb3bt2ARgGAiCYFFuwf3X5HA/McgGJWI2FdykCv4aBYzmKwDwvl6NVmUAAK2vlwEALK7fo88GANB6HQsAAAAAAAAA7P94AQCzswEAAAAAAAAAAAAAAAAAAICzh4UAO4zWAYBfRutHA4Bn5C69JhowAMGoBaMWDG0wCkbBKBgFo2AUAACPmegUST/IJAAAAABJRU5ErkJggg==>>
@@ -28,7 +28,7 @@
 Source-Repository this
     Type:      git
     Location:  git://github.com/Twinside/Juicy.Pixels.git
-    Tag:       v3.3.5
+    Tag:       v3.3.6
 
 Flag Mmap
     Description: Enable the file loading via mmap (memory map)
@@ -67,7 +67,7 @@
 
   Ghc-options: -O3 -Wall
   Build-depends: base                >= 4.8     && < 6,
-                 bytestring          >= 0.9     && < 0.11,
+                 bytestring          >= 0.9     && < 0.12,
                  mtl                 >= 1.1     && < 2.3,
                  binary              >= 0.8.1     && < 0.9,
                  zlib                >= 0.5.3.1 && < 0.7,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JuicyPixels-3.3.5/changelog 
new/JuicyPixels-3.3.6/changelog
--- old/JuicyPixels-3.3.5/changelog     2020-02-28 09:16:46.000000000 +0100
+++ new/JuicyPixels-3.3.6/changelog     2021-10-13 14:13:27.000000000 +0200
@@ -1,6 +1,15 @@
 Change log
 ==========
 
+v3.3.6 October 2021
+-------------------
+
+ * Bytestring bound bump
+ * Fix bug #187.  (Some JPEGs are misidentified as SourceTiff.)
+ * Fix EXIF handling of strings of four characters or fewer.
+ * Fix endianness bug in short ExifString and ExifUndefined.
+
+
 v3.3.5 January 2020
 -------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JuicyPixels-3.3.5/src/Codec/Picture/Bitmap.hs 
new/JuicyPixels-3.3.6/src/Codec/Picture/Bitmap.hs
--- old/JuicyPixels-3.3.5/src/Codec/Picture/Bitmap.hs   2020-02-28 
09:16:42.000000000 +0100
+++ new/JuicyPixels-3.3.6/src/Codec/Picture/Bitmap.hs   2021-10-13 
14:13:27.000000000 +0200
@@ -517,7 +517,11 @@
 
 -- | Helper method to cast a 'B.ByteString' to a 'VS.Vector' of some type.
 castByteString :: VS.Storable a => B.ByteString -> VS.Vector a
+#if MIN_VERSION_bytestring(0,11,0)
+castByteString (BI.BS fp len) = VS.unsafeCast $ VS.unsafeFromForeignPtr fp 0 
len
+#else
 castByteString (BI.PS fp offset len) = VS.unsafeCast $ VS.unsafeFromForeignPtr 
fp offset len
+#endif
 
 decodeImageRGBA8 :: RGBABmpFormat -> BmpV5Header -> B.ByteString -> Image 
PixelRGBA8
 decodeImageRGBA8 pixelFormat (BmpV5Header { width = w, height = h, bitPerPixel 
= bpp }) str = Image wi hi stArray where
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JuicyPixels-3.3.5/src/Codec/Picture/Jpg.hs 
new/JuicyPixels-3.3.6/src/Codec/Picture/Jpg.hs
--- old/JuicyPixels-3.3.5/src/Codec/Picture/Jpg.hs      2020-02-28 
09:16:42.000000000 +0100
+++ new/JuicyPixels-3.3.6/src/Codec/Picture/Jpg.hs      2021-10-13 
14:13:27.000000000 +0200
@@ -574,7 +574,7 @@
        let (st, arr) = decodeBaseline
            jfifMeta = foldMap extractMetadatas $ app0JFifMarker st
            exifMeta = foldMap extractTiffMetadata $ app1ExifMarker st
-           meta = sizeMeta <> jfifMeta <> exifMeta
+           meta = jfifMeta <> exifMeta <> sizeMeta
        in
        (, meta) <$>
            dynamicOfColorSpace (colorSpaceOfState st) imgWidth imgHeight arr
@@ -582,7 +582,7 @@
        let (st, arr) = decodeProgressive
            jfifMeta = foldMap extractMetadatas $ app0JFifMarker st
            exifMeta = foldMap extractTiffMetadata $ app1ExifMarker st
-           meta = sizeMeta <> jfifMeta <> exifMeta
+           meta = jfifMeta <> exifMeta <> sizeMeta
        in
        (, meta) <$>
            dynamicOfColorSpace (colorSpaceOfState st) imgWidth imgHeight arr
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/JuicyPixels-3.3.5/src/Codec/Picture/Tiff/Internal/Types.hs 
new/JuicyPixels-3.3.6/src/Codec/Picture/Tiff/Internal/Types.hs
--- old/JuicyPixels-3.3.5/src/Codec/Picture/Tiff/Internal/Types.hs      
2020-02-28 09:16:42.000000000 +0100
+++ new/JuicyPixels-3.3.6/src/Codec/Picture/Tiff/Internal/Types.hs      
2021-10-13 14:13:27.000000000 +0200
@@ -240,6 +240,16 @@
 
       getVec count = V.replicateM (fromIntegral count)
 
+      immediateBytes ofs =
+        let bytes = [fromIntegral $ (ofs .&. 0xFF000000) `unsafeShiftR` (3 * 8)
+                    ,fromIntegral $ (ofs .&. 0x00FF0000) `unsafeShiftR` (2 * 8)
+                    ,fromIntegral $ (ofs .&. 0x0000FF00) `unsafeShiftR` (1 * 8)
+                    ,fromIntegral $  ofs .&. 0x000000FF
+                    ]
+        in case endianness of
+             EndianLittle -> reverse bytes
+             EndianBig    -> bytes
+
       fetcher ImageFileDirectory { ifdIdentifier = TagExifOffset
                                  , ifdType = TypeLong
                                  , ifdCount = 1 } = do
@@ -262,13 +272,12 @@
          align ifd $ ExifUndefined <$> getByteString (fromIntegral count)
       fetcher ImageFileDirectory { ifdType = TypeUndefined, ifdOffset = ofs } =
           pure . ExifUndefined . B.pack $ take (fromIntegral $ ifdCount ifd)
-              [fromIntegral $ ofs .&. 0xFF000000 `unsafeShiftR` (3 * 8)
-              ,fromIntegral $ ofs .&. 0x00FF0000 `unsafeShiftR` (2 * 8)
-              ,fromIntegral $ ofs .&. 0x0000FF00 `unsafeShiftR` (1 * 8)
-              ,fromIntegral $ ofs .&. 0x000000FF
-              ]
-      fetcher ImageFileDirectory { ifdType = TypeAscii, ifdCount = count } | 
count > 1 =
+              (immediateBytes ofs)
+      fetcher ImageFileDirectory { ifdType = TypeAscii, ifdCount = count } | 
count > 4 =
           align ifd $ ExifString <$> getByteString (fromIntegral count)
+      fetcher ImageFileDirectory { ifdType = TypeAscii, ifdOffset = ofs } =
+          pure . ExifString . B.pack $ take (fromIntegral $ ifdCount ifd)
+              (immediateBytes ofs)
       fetcher ImageFileDirectory { ifdType = TypeShort, ifdCount = 2, 
ifdOffset = ofs } =
           pure . ExifShorts $ V.fromListN 2 valList
             where high = fromIntegral $ ofs `unsafeShiftR` 16
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/JuicyPixels-3.3.5/src/Codec/Picture/VectorByteConversion.hs 
new/JuicyPixels-3.3.6/src/Codec/Picture/VectorByteConversion.hs
--- old/JuicyPixels-3.3.5/src/Codec/Picture/VectorByteConversion.hs     
2018-08-14 13:07:59.000000000 +0200
+++ new/JuicyPixels-3.3.6/src/Codec/Picture/VectorByteConversion.hs     
2021-10-13 14:13:27.000000000 +0200
@@ -21,12 +21,19 @@
 
 import Codec.Picture.Types
 
+mkBS :: ForeignPtr Word8 -> Int -> Int -> S.ByteString
+#if MIN_VERSION_bytestring(0,11,0)
+mkBS fptr off = S.BS (fptr `S.plusForeignPtr` off)
+#else
+mkBS = S.PS
+#endif
+
 blitVector :: Vector Word8 -> Int -> Int -> B.ByteString
-blitVector vec atIndex = S.PS ptr (offset + atIndex)
+blitVector vec atIndex = mkBS ptr (offset + atIndex)
   where (ptr, offset, _length) = unsafeToForeignPtr vec
 
 toByteString :: forall a. (Storable a) => Vector a -> B.ByteString
-toByteString vec = S.PS (castForeignPtr ptr) offset (len * size)
+toByteString vec = mkBS (castForeignPtr ptr) offset (len * size)
   where (ptr, offset, len) = unsafeToForeignPtr vec
         size = sizeOf (undefined :: a)
 

Reply via email to