[vlc-devel] Open issue: timestamp overflows

Denis Charmet typx at dinauz.org
Mon Nov 13 10:58:38 CET 2017


Hi,

On 2017-11-12 18:33, RĂ©mi Denis-Courmont wrote:
> This leads to two and a half questions:
> 
> 1.a) What do we do if timestamp overflows? IMO, adding error cases is 
> overkill.
> We should allow timestamp to wrap around.
> 
The worst case scenario I can imagine with timestamp overflowing is an 
ES_OUT_RESET_PCR flushing the fifos. It shouldn't be too crippling. 
Besides live streaming support implies timestamps wrapping around so it 
should work.

> 1.b) Do we switch everything to date_t and handle scaling there? Do we 
> add a
> dedicated helper to rescale timestamps?
> 
It makes sense for complex demuxes like MKV but none for AVI so it 
seems a little overkill to generalize it.

> 2) How do we detect it in the first place? So far, we only have a good 
> solution
> for GCC and Clang. Do we drop standard conformance? Do we allow minor 
> UB
> issues on other compilers? Do we implement the check the hard way? Or 
> do we do
> nothing at all?
Checks are costly and I'd rather have checks for buffer sizes and 
indexes than timestamps.

Regards,
-- 
Denis Charmet - TypX
Le mauvais esprit est un art de vivre


More information about the vlc-devel mailing list