We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 2010 - Memory leaks in do_layer_surface function in IMG_xcf.c file
Summary: Memory leaks in do_layer_surface function in IMG_xcf.c file
Status: RESOLVED FIXED
Alias: None
Product: SDL_image
Classification: Unclassified
Component: misc (show other bugs)
Version: unspecified
Hardware: x86 Linux
: P2 critical
Assignee: Sam Lantinga
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-08-05 05:48 UTC by Nitz
Modified: 2013-08-07 12:18 UTC (History)
0 users

See Also:


Attachments
do_layer_surface patch for memory leaks (3.89 KB, text/plain)
2013-08-05 05:49 UTC, Nitz
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nitz 2013-08-05 05:48:25 UTC
In static int do_layer_surface (SDL_Surface * surface, SDL_RWops * src, xcf_header * head, xcf_layer * layer, load_tile_type load_tile)

hierarchy, level and tile pointers are getting leak at default cases of switch statement.
I have attached the modified function, kindly see the diff.

Cheers.
Comment 1 Nitz 2013-08-05 05:49:46 UTC
Created attachment 1271 [details]
do_layer_surface patch for memory leaks
Comment 2 Sam Lantinga 2013-08-07 12:18:58 UTC
Fixed, thanks!
http://hg.libsdl.org/SDL_image/rev/e108e1228d62