unsigned int jam_getheight(void *stream);
double jam_getframerate(void *stream);
int jam_video(void *stream, void *imagedata, unsigned int Rmask, unsigned int Gmask, unsigned int Bmask, unsigned int bytesperpixel, int imagebytesperrow);
-void *jam_open(clvideo_t *video, char *filename, const char **errorstring)
+static void *jam_open(clvideo_t *video, char *filename, const char **errorstring)
{
unsigned char jamHead[16];
char *wavename;
// decode JAM frame
-void jam_decodeframe(unsigned char *inbuf, unsigned char *outbuf, unsigned char *prevbuf, int outsize, int frametype)
+static void jam_decodeframe(unsigned char *inbuf, unsigned char *outbuf, unsigned char *prevbuf, int outsize, int frametype)
{
unsigned char *srcptr, *destptr, *prevptr;
int bytesleft;
{
compsize = LittleLong(*(frameHead + 8)) - 16;
outsize = LittleLong(*(frameHead + 12));
- if (compsize < 0 || compsize > s->framesize || outsize < 0 || outsize > s->framesize)
+ if (compsize > s->framesize || outsize > s->framesize)
s->error = JAMDECODEERROR_BAD_FRAME_HEADER;
else if (FS_Read(s->file, s->compressed, compsize))
{
else
s->error = DPVSIMPLEDECODEERROR_EOF;
return s->error;
-}
\ No newline at end of file
+}