For source code file xzgv-0.8/src/main.c
function read_xvpic
I notice the following poorly formatted code
count=fread(bmap,1,w*h,in);
if(count!=w*h)
return(0);
fclose(in);
return(1);
so if the first return is taken, then local variable "in" is a resource leak.
Suggest new code
count = fread( bmap, 1, w * h, in);
fclose( in);
if (count != w * h)
return 0;
else
return 1;
This issue was solved by commit 71c8267.