mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-17 23:21:22 +00:00
Merge branch 'freemipmapcolormap-momento-irmao' into 'master'
Fix FreeMipmapColormap yet again See merge request STJr/SRB2Internal!597
This commit is contained in:
commit
6b344b9ddf
1 changed files with 4 additions and 1 deletions
|
@ -781,9 +781,12 @@ static void FreeMipmapColormap(INT32 patchnum, void *patch)
|
|||
// Confusing at first, but pat->mipmap->nextcolormap
|
||||
// at the beginning of the loop is the first colormap
|
||||
// from the linked list of colormaps
|
||||
GLMipmap_t *next = pat->mipmap->nextcolormap;
|
||||
GLMipmap_t *next = pat->mipmap;
|
||||
if (!next) // No mipmap in this patch, break out of loop.
|
||||
break;
|
||||
// Set the first colormap
|
||||
// to the one that comes after it
|
||||
next = next->nextcolormap;
|
||||
pat->mipmap->nextcolormap = next->nextcolormap;
|
||||
// Free image data from memory
|
||||
if (next->grInfo.data)
|
||||
|
|
Loading…
Reference in a new issue