Permalink
Browse files

packetizer: hevc: fix divbyzero

num being used as den in date operations
  • Loading branch information...
fcartegnie committed Jul 19, 2017
1 parent 7eea089 commit 4b76784615f74254a7b66e34ff78393b44af2ed5
Showing with 2 additions and 1 deletion.
  1. +2 −1 modules/packetizer/hevc.c
@@ -189,7 +189,8 @@ static int Open(vlc_object_t *p_this)
p_dec->fmt_out.b_packetized = true;

/* Init timings */
if( p_dec->fmt_in.video.i_frame_rate_base > 0 )
if( p_dec->fmt_in.video.i_frame_rate_base &&
p_dec->fmt_in.video.i_frame_rate )
date_Init( &p_sys->dts, p_dec->fmt_in.video.i_frame_rate * 2,
p_dec->fmt_in.video.i_frame_rate_base );
else

0 comments on commit 4b76784

Please sign in to comment.