Mercurial > hg > dmlib
changeset 1808:4b08e6a26564
Move idILBM variable to DMIFF struct.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Thu, 21 Jun 2018 11:13:19 +0300 |
parents | d53bdee5ffa5 |
children | a20655e40e6c |
files | tools/libgfx.c |
diffstat | 1 files changed, 4 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/tools/libgfx.c Tue Jun 19 13:26:48 2018 +0300 +++ b/tools/libgfx.c Thu Jun 21 11:13:19 2018 +0300 @@ -1482,7 +1482,7 @@ { DMIFFChunk chBMHD, chCMAP, chBODY; DMIFFBMHD bmhd; - Uint32 camg; + Uint32 camg, idILBM; int ncolors; DMColor *pal; BOOL planar; @@ -1741,7 +1741,6 @@ int dmReadILBMImageFILE(DMResource *fp, DMImage **pimg) { - Uint32 idILBM; DMIFFChunk chunk; DMIFF iff; Uint32 read; @@ -1762,14 +1761,14 @@ } // Check IFF ILBM signature - if (!dmf_read_be32(fp, &idILBM) || - (idILBM != IFF_ID_ILBM && idILBM != IFF_ID_PBM)) + if (!dmf_read_be32(fp, &iff.idILBM) || + (iff.idILBM != IFF_ID_ILBM && iff.idILBM != IFF_ID_PBM)) { return dmError(DMERR_INVALID_DATA, "ILBM: Not a ILBM file.\n"); } - iff.planar = (idILBM == IFF_ID_ILBM); + iff.planar = (iff.idILBM == IFF_ID_ILBM); while (!parsed && !dmfeof(fp)) {