Petr Gajdos
33ad9176ce
- added patches CVE-2019-15142 [bsc#1146702] + djvulibre-CVE-2019-15142.patch CVE-2019-15143 [bsc#1146569] + djvulibre-CVE-2019-15143.patch CVE-2019-15144 [bsc#1146571] + djvulibre-CVE-2019-15144.patch CVE-2019-15145 [bsc#1146572] + djvulibre-CVE-2019-15145.patch do not segfault when libtiff encounters corrupted TIFF (upstream issue #295) + djvulibre-invalid-tiff.patch OBS-URL: https://build.opensuse.org/package/show/graphics/djvulibre?expand=0&rev=28
23 lines
685 B
Diff
23 lines
685 B
Diff
diff --git a/libdjvu/GBitmap.h b/libdjvu/GBitmap.h
|
|
index e8e0c9b..ca89a19 100644
|
|
--- a/libdjvu/GBitmap.h
|
|
+++ b/libdjvu/GBitmap.h
|
|
@@ -566,7 +566,7 @@ GBitmap::operator[](int row)
|
|
{
|
|
if (!bytes)
|
|
uncompress();
|
|
- if (row<0 || row>=nrows) {
|
|
+ if (row<0 || row>=nrows || !bytes) {
|
|
#ifndef NDEBUG
|
|
if (zerosize < bytes_per_row + border)
|
|
G_THROW( ERR_MSG("GBitmap.zero_small") );
|
|
@@ -581,7 +581,7 @@ GBitmap::operator[](int row) const
|
|
{
|
|
if (!bytes)
|
|
((GBitmap*)this)->uncompress();
|
|
- if (row<0 || row>=nrows) {
|
|
+ if (row<0 || row>=nrows || !bytes) {
|
|
#ifndef NDEBUG
|
|
if (zerosize < bytes_per_row + border)
|
|
G_THROW( ERR_MSG("GBitmap.zero_small") );
|