aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-01-24 14:18:25 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-01-24 14:18:30 +0100
commitb4581e9394c9f97d08af814d09337ed16f21cfe0 (patch)
treec1af301bb0e8eaab4e57a1cf6f6bb984cbe53167
parent1d2abca7e1f09ccd2f14b4d452aab584362fad33 (diff)
parent4a4a7e138c92901e04db46a6b05cc6948023e5f5 (diff)
downloadffmpeg-b4581e9394c9f97d08af814d09337ed16f21cfe0.tar.gz
Merge commit '4a4a7e138c92901e04db46a6b05cc6948023e5f5'
* commit '4a4a7e138c92901e04db46a6b05cc6948023e5f5': rtpenc_chain: Use the original AVFormatContext for getting payload type rtp: Make sure the output format pointer is set Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavformat/rtp.c2
-rw-r--r--libavformat/rtpenc_chain.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/rtp.c b/libavformat/rtp.c
index e81d2c2ad8..b76e521a8c 100644
--- a/libavformat/rtp.c
+++ b/libavformat/rtp.c
@@ -103,7 +103,7 @@ int ff_rtp_get_payload_type(AVFormatContext *fmt,
/* static payload type */
for (i = 0; rtp_payload_types[i].pt >= 0; ++i)
if (rtp_payload_types[i].codec_id == codec->codec_id) {
- if (codec->codec_id == AV_CODEC_ID_H263 && (!fmt ||
+ if (codec->codec_id == AV_CODEC_ID_H263 && (!fmt || !fmt->oformat ||
!fmt->oformat->priv_class || !fmt->priv_data ||
!av_opt_flag_is_set(fmt->priv_data, "rtpflags", "rfc2190")))
continue;
diff --git a/libavformat/rtpenc_chain.c b/libavformat/rtpenc_chain.c
index df7410d0c8..70d68ce534 100644
--- a/libavformat/rtpenc_chain.c
+++ b/libavformat/rtpenc_chain.c
@@ -64,7 +64,7 @@ int ff_rtp_chain_mux_open(AVFormatContext **out, AVFormatContext *s,
/* Get the payload type from the codec */
if (st->id < RTP_PT_PRIVATE)
rtpctx->streams[0]->id =
- ff_rtp_get_payload_type(rtpctx, st->codec, idx);
+ ff_rtp_get_payload_type(s, st->codec, idx);
else
rtpctx->streams[0]->id = st->id;