[shotwell/shotwell-0.26] Remove postfix trimming of thumbs on Canon files



commit 5b888386b8c0e40a94a356bf6d5420e741ebfda1
Author: Peter Seiderer <ps report gmx net>
Date:   Sun Feb 5 00:08:00 2012 +0000

    Remove postfix trimming of thumbs on Canon files
    
    Apparently, exiv2 now also gets them out of the images, breaking the
    duplicate detection (for Canon cameras)
    
    https://bugzilla.gnome.org/show_bug.cgi?id=717735

 src/camera/GPhoto.vala |   14 --------------
 1 files changed, 0 insertions(+), 14 deletions(-)
---
diff --git a/src/camera/GPhoto.vala b/src/camera/GPhoto.vala
index 5919080..8dab941 100644
--- a/src/camera/GPhoto.vala
+++ b/src/camera/GPhoto.vala
@@ -169,20 +169,6 @@ namespace GPhoto {
         
         raw_length = raw.length;
         
-        // Try to make sure last two bytes are JPEG footer.
-        // This is necessary because GPhoto sometimes includes a few extra bytes. See
-        // Yorba bug #2905 and the following GPhoto bug:
-        // http://sourceforge.net/tracker/?func=detail&aid=3141521&group_id=8874&atid=108874
-        if (raw_length > 32) {
-            for (size_t i = raw_length - 2; i > raw_length - 32; i--) {
-                if (raw[i] == Jpeg.MARKER_PREFIX && raw[i + 1] == Jpeg.Marker.EOI) {
-                    debug("Adjusted length of thumbnail for: %s", filename);
-                    raw_length = i + 2;
-                    break;
-                }
-            }
-        }
-        
         MemoryInputStream mins = new MemoryInputStream.from_data(raw, null);
         return new Gdk.Pixbuf.from_stream_at_scale(mins, ImportPreview.MAX_SCALE, ImportPreview.MAX_SCALE, 
true, null);
     }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]