changeset 12546:7f8ae1376d6c

We don't want junk in unused parts of the BITMAPINFOHEADER
author ranma
date Tue, 08 Jun 2004 16:43:24 +0000
parents 868376f81c30
children a60ba1b93e25
files mencoder.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mencoder.c	Mon Jun 07 19:23:04 2004 +0000
+++ b/mencoder.c	Tue Jun 08 16:43:24 2004 +0000
@@ -663,7 +663,7 @@
 	mux_v->bih=sh_video->bih;
     else
     {
-	mux_v->bih=malloc(sizeof(BITMAPINFOHEADER));
+	mux_v->bih=calloc(1,sizeof(BITMAPINFOHEADER));
 	mux_v->bih->biSize=sizeof(BITMAPINFOHEADER);
 	mux_v->bih->biWidth=sh_video->disp_w;
 	mux_v->bih->biHeight=sh_video->disp_h;
@@ -677,7 +677,7 @@
 	mux_v->bih->biBitCount, mux_v->bih->biCompression);
     break;
 case VCODEC_FRAMENO:
-    mux_v->bih=malloc(sizeof(BITMAPINFOHEADER));
+    mux_v->bih=calloc(1,sizeof(BITMAPINFOHEADER));
     mux_v->bih->biSize=sizeof(BITMAPINFOHEADER);
     mux_v->bih->biWidth=sh_video->disp_w;
     mux_v->bih->biHeight=sh_video->disp_h;