From 65cc2366a34f3e572be0fa59e7d70f8b57e526ea Mon Sep 17 00:00:00 2001 From: siretart Date: Sun, 9 Jan 2011 20:02:45 +0000 Subject: TOOLS/: minor fixes in tool code Fix printf format string warning fixes this warning: asfinfo.c: In function 'print_video_header': asfinfo.c:158: warning: format '%.4s' expects type 'char *', but argument 3 has type 'long int *' git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32774 b3059339-0415-0410-9bf9-f77b7e298cf2 add missing fclose git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32775 b3059339-0415-0410-9bf9-f77b7e298cf2 add missing fclose() found by cppcheck: [avisubdump.c:199]: (error) Resource leak: f git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32776 b3059339-0415-0410-9bf9-f77b7e298cf2 --- TOOLS/asfinfo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'TOOLS/asfinfo.c') diff --git a/TOOLS/asfinfo.c b/TOOLS/asfinfo.c index 85883b462f..739bbcc0c7 100644 --- a/TOOLS/asfinfo.c +++ b/TOOLS/asfinfo.c @@ -155,7 +155,7 @@ static void print_video_header(BITMAPINFOHEADER *h){ printf(" biHeight %ld\n", h->biHeight); printf(" biPlanes %d\n", h->biPlanes); printf(" biBitCount %d\n", h->biBitCount); - printf(" biCompression %ld='%.4s'\n", h->biCompression, &h->biCompression); + printf(" biCompression %ld='%.4s'\n", h->biCompression, (const char*)&h->biCompression); printf(" biSizeImage %ld\n", h->biSizeImage); printf("===========================\n"); } @@ -284,5 +284,6 @@ int main(int argc, char* argv[]){ fseek(f, pos + objh.size - sizeof(objh), SEEK_SET); } + fclose(f); return 0; } -- cgit v1.2.3