Commit b4e3330c authored by Ronald S. Bultje's avatar Ronald S. Bultje

Make rtp_parse_packet() always call the vfunc of the dynamic payload handler

if there is one. See "[PATCH] Realmedia / RTSP (RDT)" thread on ML.

Originally committed as revision 11493 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 927688d6
...@@ -474,6 +474,8 @@ int rtp_parse_packet(RTPDemuxContext *s, AVPacket *pkt, ...@@ -474,6 +474,8 @@ int rtp_parse_packet(RTPDemuxContext *s, AVPacket *pkt,
s->read_buf_index = 0; s->read_buf_index = 0;
return 1; return 1;
} }
} else if (s->parse_packet) {
rv = s->parse_packet(s, pkt, &timestamp, buf, len);
} else { } else {
// at this point, the RTP header has been stripped; This is ASSUMING that there is only 1 CSRC, which in't wise. // at this point, the RTP header has been stripped; This is ASSUMING that there is only 1 CSRC, which in't wise.
switch(st->codec->codec_id) { switch(st->codec->codec_id) {
...@@ -529,12 +531,8 @@ int rtp_parse_packet(RTPDemuxContext *s, AVPacket *pkt, ...@@ -529,12 +531,8 @@ int rtp_parse_packet(RTPDemuxContext *s, AVPacket *pkt,
rv= 0; rv= 0;
break; break;
default: default:
if(s->parse_packet) {
rv= s->parse_packet(s, pkt, &timestamp, buf, len);
} else {
av_new_packet(pkt, len); av_new_packet(pkt, len);
memcpy(pkt->data, buf, len); memcpy(pkt->data, buf, len);
}
break; break;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment