[vlc-commits] a52: fix FPE when fmt_out.i_rate is already initialized

Thomas Guillem git at videolan.org
Tue Nov 14 11:23:57 CET 2017


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Tue Nov 14 11:17:07 2017 +0100| [ba6b88f01dea8ed4566f376d89dde0934c455d93] | committer: Thomas Guillem

a52: fix FPE when fmt_out.i_rate is already initialized

If fmt_out.i_rate is already set to a good value from Open(), date_Init() is
not called and date_Increment() triggers a FPE.

This is a regression from 31a4ceafbc7777ce1894e9061798877040cb1118

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ba6b88f01dea8ed4566f376d89dde0934c455d93
---

 modules/packetizer/a52.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/modules/packetizer/a52.c b/modules/packetizer/a52.c
index cc3cea6bad..59d6aa9701 100644
--- a/modules/packetizer/a52.c
+++ b/modules/packetizer/a52.c
@@ -343,6 +343,7 @@ static int Open( vlc_object_t *p_this )
     /* Set output properties (Passthrough ONLY) */
     p_dec->fmt_out.i_codec = p_dec->fmt_in.i_codec;
     p_dec->fmt_out.audio = p_dec->fmt_in.audio;
+    p_dec->fmt_out.audio.i_rate = 0;
 
     /* Set callback */
     p_dec->pf_packetize = PacketizeBlock;



More information about the vlc-commits mailing list