Skip to content
Snippets Groups Projects
Commit 841c1522 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont
Browse files

rtp: do not overflow PTS (fixes #26258)

VLC does not handle negative timestamps so far. So the initial NTP
reference timestamp should be positive enough that the extrapolated
PTS will not end up negative when the RTP packet timestamp is lower
than the reference RTP timestamp. In that case the PTS is lower than
the NTP reference.

While 2^62 was a very safe value in that respect, it lead to integer
overflows in the clock and in time base conversion code. To avoid this,
we pick a default NTP reference value equal to the closest power of two
of the NTP time of this changeset: 2^52 is in 2042 CE, 2^51 in 1971 CE.
parent c8c78f75
No related branches found
No related tags found
1 merge request!953RTP MPEG 1/2 payload formats
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment