LibRaw/LibRaw-0.14.8-errorhandling.patch
2013-05-31 05:40:22 -05:00

50 lines
2.4 KiB
Diff
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

diff -U3 -r LibRaw-0.14.8.orig/Changelog.rus LibRaw-0.14.8/Changelog.rus
--- LibRaw-0.14.8.orig/Changelog.rus 2013-05-17 14:54:17.000000000 -0500
+++ LibRaw-0.14.8/Changelog.rus 2013-05-31 05:31:45.970607271 -0500
@@ -1,4 +1,8 @@
-2013-05-21 Alex Tutubalin <lexa@lexa.ru>
+2013-05-31 Alex Tutubalin <lexa@lexa.ru>
+ * Исправлена ошибка при обработке поврежденных полноцветных
+ файлов (sRAW, Foveon)
+
+2013-05-21 Alex Tutubalin <lexa@lexa.ru>
* Исправлена ошибка в коде функции sony_decrypt(), приводившая
к неверному чтению камерного баланса белого на камерах Sony
если LibRaw была собрана gcc 4.8
diff -U3 -r LibRaw-0.14.8.orig/Changelog.txt LibRaw-0.14.8/Changelog.txt
--- LibRaw-0.14.8.orig/Changelog.txt 2013-05-17 14:54:17.000000000 -0500
+++ LibRaw-0.14.8/Changelog.txt 2013-05-31 05:31:45.970607271 -0500
@@ -1,3 +1,7 @@
+2013-05-31 Alex Tutubalin <lexa@lexa.ru>
+ * Fixed double call to free() on broken legacy-layout images
+ (backport from 0.15.x)
+
2013-05-21 Alex Tutubalin <lexa@lexa.ru>
* Fixed undefined behaviour in sony_decrypt() function.
This bug causes incorrect camera WB read for Sony cameras.
diff -U3 -r LibRaw-0.14.8.orig/src/libraw_cxx.cpp LibRaw-0.14.8/src/libraw_cxx.cpp
--- LibRaw-0.14.8.orig/src/libraw_cxx.cpp 2013-05-17 14:54:17.000000000 -0500
+++ LibRaw-0.14.8/src/libraw_cxx.cpp 2013-05-31 05:31:51.402607149 -0500
@@ -796,8 +796,8 @@
S.iheight= S.height;
IO.shrink = 0;
// allocate image as temporary buffer, size
- imgdata.rawdata.raw_alloc = calloc(S.iwidth*S.iheight,sizeof(*imgdata.image));
- imgdata.image = (ushort (*)[4]) imgdata.rawdata.raw_alloc;
+ imgdata.rawdata.raw_alloc = 0;
+ imgdata.image = (ushort (*)[4]) calloc(S.iwidth*S.iheight,sizeof(*imgdata.image));
}
@@ -807,8 +807,8 @@
// recover saved
if( decoder_info.decoder_flags & LIBRAW_DECODER_LEGACY)
{
- imgdata.image = 0;
- imgdata.rawdata.color_image = (ushort (*)[4]) imgdata.rawdata.raw_alloc;
+ imgdata.rawdata.raw_alloc = imgdata.rawdata.color_image = imgdata.image;
+ imgdata.image = 0;
}
// calculate channel maximum