Commit fd433550 authored by Rafaël Carré's avatar Rafaël Carré Committed by Jean-Baptiste Kempf

avformat mux: don't write trailer if writing header failed

(cherry picked from commit 62229a3b)
Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent c058582a
......@@ -173,7 +173,7 @@ void CloseMux( vlc_object_t *p_this )
sout_mux_sys_t *p_sys = p_mux->p_sys;
unsigned int i;
if( !p_sys->b_write_header && av_write_trailer( p_sys->oc ) < 0 )
if( !p_sys->b_write_header && !p_sys->b_error && av_write_trailer( p_sys->oc ) < 0 )
{
msg_Err( p_mux, "could not write trailer" );
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment