diff --git a/libavformat/rtpdec.c b/libavformat/rtpdec.c index 66f2310b2f..ba2f506c9e 100644 --- a/libavformat/rtpdec.c +++ b/libavformat/rtpdec.c @@ -531,8 +531,8 @@ int rtp_parse_packet(RTPDemuxContext *s, AVPacket *pkt, rv= 0; break; default: - av_new_packet(pkt, len); - memcpy(pkt->data, buf, len); + av_new_packet(pkt, len); + memcpy(pkt->data, buf, len); break; }