Buf[GIF_STAMP_LEN] = 0;
if (strncmp(GIF_STAMP, (const char *) Buf, GIF_VERSION_POS) != 0) {
GifInternError(GifFile, D_GIF_ERR_NOT_GIF_FILE);
- }
+ }
DGifGetScreenDesc(GifFile);
}
MakeMapObject (GifFile->Image.ColorMap->ColorCount,
GifFile->Image.ColorMap->Colors);
}
- sp->RasterBits = (GifPixelType *)NULL;
+ sp->RasterBits = NULL;
sp->ExtensionBlockCount = 0;
sp->ExtensionBlocks = (ExtensionBlock *)NULL;
}
ImageSize = sp->ImageDesc.Width * sp->ImageDesc.Height;
sp->RasterBits
- = (GifPixelType*) malloc(ImageSize * sizeof(GifPixelType));
+ = (GifPixelType*) malloc (ImageSize * sizeof(GifPixelType));
DGifGetLine(GifFile, sp->RasterBits, ImageSize);
break;
CopyFrom->ImageDesc.ColorMap->Colors);
/* next, the raster */
- sp->RasterBits = (GifPixelType*)malloc(sizeof(GifPixelType)
+ sp->RasterBits = (GifPixelType *) malloc(sizeof(GifPixelType)
* CopyFrom->ImageDesc.Height
* CopyFrom->ImageDesc.Width);
memcpy(sp->RasterBits,
* Miscellaneous utility functions *
******************************************************************************/
-int BitSize(int n)
+static int BitSize(int n)
/* return smallest bitfield size n will fit in */
{
register int i;