Author: post
Date: 2010-04-25 21:25:27 +0200 (Sun, 25 Apr 2010)
New Revision: 229

Modified:
   RawSpeed/DngDecoder.cpp
Log:
DNG Decoder: Abort on error in first uncompressed DNG slice + remember to 
duplicate error string.

Modified: RawSpeed/DngDecoder.cpp
===================================================================
--- RawSpeed/DngDecoder.cpp     2010-04-25 12:43:23 UTC (rev 228)
+++ RawSpeed/DngDecoder.cpp     2010-04-25 19:25:27 UTC (rev 229)
@@ -197,8 +197,10 @@
           try {
             readUncompressedRaw(in, size, pos, width*bps / 8, bps, big_endian);
           } catch(IOException ex) {
-            errors.push_back(ex.what());
-            // Let's ignore this, we may have some valid data.
+            if (i > 0)
+              errors.push_back(_strdup(ex.what()));
+            else
+              ThrowRDE("DNG decoder: IO error occurred in first slice, unable 
to decode more. Error is: %s", ex.what());
           }
         }
 


_______________________________________________
Rawstudio-commit mailing list
[email protected]
http://rawstudio.org/cgi-bin/mailman/listinfo/rawstudio-commit

Reply via email to