bug#49149, 48797, 47098: fix leak in gif colormap (local and global).

git-svn-id: svn://10.0.0.236/trunk@76903 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
pnunn%netscape.com
2000-08-22 23:32:31 +00:00
parent 584b358c88
commit b337cf4d81

View File

@@ -1679,16 +1679,18 @@ il_gif_abort(il_container *ic)
* present, will be freed when the image container is
* destroyed.
*/
if (gs->is_local_colormap_defined) {
if (gs->global_colormap) {
PR_FREEIF(gs->global_colormap);
gs->global_colormap = NULL;
}
} else {
if (gs->local_colormap) {
PR_FREEIF(gs->local_colormap);
gs->local_colormap = NULL;
ic->src_header->color_space->cmap.map = NULL;
}
} else {
if (gs->global_colormap) {
PR_FREEIF(gs->global_colormap);
gs->global_colormap = NULL;
ic->src_header->color_space->cmap.map = NULL;
}
}