mirror of https://github.com/GNOME/gimp.git
workaround for bug #357809: avoid crashing when invalid offsets are read
2006-10-11 Raphael Quinet <raphael@gimp.org> * app/xcf/xcf-load.c (xcf_load_tile_rle): workaround for bug #357809: avoid crashing when invalid offsets are read for a compressed tile in the XCF file.
This commit is contained in:
parent
09eb46429d
commit
e6615a2bf7
|
@ -1,3 +1,9 @@
|
|||
2006-10-11 Raphaël Quinet <raphael@gimp.org>
|
||||
|
||||
* app/xcf/xcf-load.c (xcf_load_tile_rle): workaround for bug
|
||||
#357809: avoid crashing when invalid offsets are read for a
|
||||
compressed tile in the XCF file.
|
||||
|
||||
2006-10-11 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* modules/Makefile.am: build the color-managed CMYK color selector
|
||||
|
|
|
@ -1365,6 +1365,15 @@ xcf_load_tile_rle (XcfInfo *info,
|
|||
gint nmemb_read_successfully;
|
||||
guchar *xcfdata, *xcfodata, *xcfdatalimit;
|
||||
|
||||
/* Workaround for bug #357809: avoid crashing on g_malloc() and skip
|
||||
* this tile (return TRUE without storing data) as if it did not
|
||||
* contain any data. It is better than returning FALSE, which would
|
||||
* skip the whole hierarchy while there may still be some valid
|
||||
* tiles in the file.
|
||||
*/
|
||||
if (data_length <= 0)
|
||||
return TRUE;
|
||||
|
||||
data = tile_data_pointer (tile, 0, 0);
|
||||
bpp = tile_bpp (tile);
|
||||
|
||||
|
|
Loading…
Reference in New Issue