]> git.sesse.net Git - ffmpeg/blobdiff - libavformat/rtp.c
asfenc: return error on negative timestamp
[ffmpeg] / libavformat / rtp.c
index d1c6ed09aa27adac7cbf78746d1a557ccb9133aa..0a3c411f51e9125f1449b9c0f54e5a59a86d2781 100644 (file)
@@ -19,7 +19,7 @@
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
-#include <libavutil/opt.h>
+#include "libavutil/opt.h"
 #include "avformat.h"
 
 #include "rtp.h"
@@ -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;