From 7e564ad5c3244e601f702a430bc20c6e33f9b08a Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Tue, 30 Jun 2009 22:14:08 +0200 Subject: [PATCH 1/5] In InitGLX13(), make sure fbconf has a defined value. Otherwise the for loop may be left to early. --- modules/video_output/x11/glx.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/modules/video_output/x11/glx.c b/modules/video_output/x11/glx.c index 1d8df41..06c1dbd 100644 --- a/modules/video_output/x11/glx.c +++ b/modules/video_output/x11/glx.c @@ -234,7 +234,7 @@ int InitGLX13( vout_thread_t *p_vout ) { vout_sys_t *p_sys = p_vout->p_sys; int i_nb, ret = VLC_EGENERIC; - GLXFBConfig *p_fbconfs = NULL, fbconf; + GLXFBConfig *p_fbconfs = NULL, fbconf = NULL; XWindowAttributes att; static const int p_attr[] = { GLX_RED_SIZE, 5, GLX_GREEN_SIZE, 5, GLX_BLUE_SIZE, 5, -- 1.6.3.2 From 049d8fae1e55946c66966d1c54d65291c0d0634e Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Tue, 30 Jun 2009 22:24:59 +0200 Subject: [PATCH 2/5] In httpd_FileCallBack(), make sure p_body has a defined values. It may be passed to free() after all. --- src/network/httpd.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/src/network/httpd.c b/src/network/httpd.c index 62741ff..9c759ad 100644 --- a/src/network/httpd.c +++ b/src/network/httpd.c @@ -394,7 +394,7 @@ httpd_FileCallBack( httpd_callback_sys_t *p_sys, httpd_client_t *cl, httpd_message_t *answer, const httpd_message_t *query ) { httpd_file_t *file = (httpd_file_t*)p_sys; - uint8_t **pp_body, *p_body; + uint8_t **pp_body, *p_body = NULL; const char *psz_connection; int *pi_body, i_body; @@ -419,7 +419,6 @@ httpd_FileCallBack( httpd_callback_sys_t *p_sys, httpd_client_t *cl, else { /* The file still needs to be executed. */ - p_body = NULL; i_body = 0; pp_body = &p_body; pi_body = &i_body; -- 1.6.3.2 From 38fe28617c6e5745b8da51c2e60da53211ed81f5 Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Wed, 1 Jul 2009 19:11:06 +0200 Subject: [PATCH 3/5] Remove write-only variable i_maxbytespersec in avi_HeaderCreateRIFF(). --- modules/mux/avi.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/modules/mux/avi.c b/modules/mux/avi.c index 9e3c2d8..9ab6e6a 100644 --- a/modules/mux/avi.c +++ b/modules/mux/avi.c @@ -805,7 +805,6 @@ static block_t *avi_HeaderCreateRIFF( sout_mux_t *p_mux ) sout_mux_sys_t *p_sys = p_mux->p_sys; block_t *p_hdr; int i_stream; - int i_maxbytespersec; int i_junk; buffer_out_t bo; @@ -823,7 +822,7 @@ static block_t *avi_HeaderCreateRIFF( sout_mux_t *p_mux ) bo_AddFCC( &bo, "hdrl" ); avi_HeaderAdd_avih( p_mux, &bo ); - for( i_stream = 0,i_maxbytespersec = 0; i_stream < p_sys->i_streams; i_stream++ ) + for( i_stream = 0; i_stream < p_sys->i_streams; i_stream++ ) { avi_HeaderAdd_strl( &bo, &p_sys->stream[i_stream] ); } -- 1.6.3.2 From 5b21bd4a60bffc85578ed3910441936a6e75072e Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Wed, 1 Jul 2009 19:45:41 +0200 Subject: [PATCH 4/5] In HandleMessage(), don't let the 0xF0 case fallthrough. Otherwise setting datalen would be pointless. --- modules/demux/smf.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/modules/demux/smf.c b/modules/demux/smf.c index 26367a0..dcc1e4b 100644 --- a/modules/demux/smf.c +++ b/modules/demux/smf.c @@ -512,6 +512,7 @@ int HandleMessage (demux_t *p_demux, mtrk_t *tr) datalen = 0; break; } + break; case 0xC0: case 0xD0: datalen = 1; -- 1.6.3.2 From 1e7cf22e3377cfd9d7e844f36a74b298df6ed2ed Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Wed, 1 Jul 2009 19:48:30 +0200 Subject: [PATCH 5/5] Let HandleMeta return ret instead of 0, why else would be bother setting it. --- modules/demux/smf.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/modules/demux/smf.c b/modules/demux/smf.c index dcc1e4b..5766cb4 100644 --- a/modules/demux/smf.c +++ b/modules/demux/smf.c @@ -449,7 +449,7 @@ int HandleMeta (demux_t *p_demux, mtrk_t *tr) } free (payload); - return 0; + return ret; } -- 1.6.3.2