summaryrefslogtreecommitdiff
path: root/libavformat/rtmppkt.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-01-21 04:20:47 +0100
committerMichael Niedermayer <michaelni@gmx.at>2014-01-21 04:20:50 +0100
commit1c7d2870440fcf3c11dadb8b060cc8ee0ffeafc5 (patch)
treeb7273dc205002a9e0b9515b268ae6affdeee05fb /libavformat/rtmppkt.c
parentca9d7c57f4b0fde0f1558b44a7bd6c80028b74be (diff)
parent89564be444d24f75ea5add8b6987e414cf7aa7d5 (diff)
Merge commit '89564be444d24f75ea5add8b6987e414cf7aa7d5'
* commit '89564be444d24f75ea5add8b6987e414cf7aa7d5': rtmpproto: Send a full, absolute timestamp if it isn't monotonically growing Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/rtmppkt.c')
-rw-r--r--libavformat/rtmppkt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/rtmppkt.c b/libavformat/rtmppkt.c
index 375ae2fcb1..f99540cd51 100644
--- a/libavformat/rtmppkt.c
+++ b/libavformat/rtmppkt.c
@@ -313,7 +313,8 @@ int ff_rtmp_packet_write(URLContext *h, RTMPPacket *pkt,
//if channel_id = 0, this is first presentation of prev_pkt, send full hdr.
if (prev_pkt[pkt->channel_id].channel_id &&
- pkt->extra == prev_pkt[pkt->channel_id].extra) {
+ pkt->extra == prev_pkt[pkt->channel_id].extra &&
+ pkt->timestamp >= prev_pkt[pkt->channel_id].timestamp) {
if (pkt->type == prev_pkt[pkt->channel_id].type &&
pkt->size == prev_pkt[pkt->channel_id].size) {
mode = RTMP_PS_FOURBYTES;