[Commits] SDL_image: xcf: don't double-free a pointer on bogus data.

libsdl.org revision control commits-owner at libsdl.org
Sat Jan 27 19:50:25 PST 2018


details:   https://hg.libsdl.org/SDL_image/rev/d0142861559c
changeset: 562:d0142861559c
user:      Ryan C. Gordon <icculus at icculus.org>
date:      Sat Jan 27 22:50:18 2018 -0500
description:
xcf: don't double-free a pointer on bogus data.

free_xcf_hierarchy() frees the same pointer that this code manually frees.

diffstat:

 IMG_xcf.c |  3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diffs (13 lines):

diff -r 607436eb1473 -r d0142861559c IMG_xcf.c
--- a/IMG_xcf.c	Sat Jan 27 17:31:24 2018 -0500
+++ b/IMG_xcf.c	Sat Jan 27 22:50:18 2018 -0500
@@ -651,9 +651,6 @@
                     default:
                         SDL_Log("Unknown Gimp image type (%d)\n", head->image_type);
                         if (hierarchy) {
-                            if (hierarchy->level_file_offsets)
-                                SDL_free(hierarchy->level_file_offsets);
-
                             free_xcf_hierarchy(hierarchy);
                         }
                         if (level)


More information about the commits mailing list