From 2cf4bd7751c1920c840a3afc6dce39535def47f2 Mon Sep 17 00:00:00 2001 From: Carl Date: Mon, 28 Nov 2011 04:22:11 +0100 Subject: sdp: Fix null pointer dereference with aac and ffserver. Signed-off-by: Michael Niedermayer --- libavformat/sdp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libavformat/sdp.c') diff --git a/libavformat/sdp.c b/libavformat/sdp.c index 37eee26485..13c5ba6629 100644 --- a/libavformat/sdp.c +++ b/libavformat/sdp.c @@ -402,7 +402,7 @@ static char *sdp_write_media_attributes(char *buff, int size, AVCodecContext *c, payload_type, config ? config : ""); break; case CODEC_ID_AAC: - if (fmt && fmt->oformat->priv_class && + if (fmt && fmt->oformat && fmt->oformat->priv_class && av_opt_flag_is_set(fmt->priv_data, "rtpflags", "latm")) { config = latm_context2config(c); if (!config) -- cgit v1.2.3