Commit cbe43e62 authored by Michael Niedermayer's avatar Michael Niedermayer

ffserver: set oformat

Fix Ticket1986
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent cef28b56
......@@ -2961,12 +2961,14 @@ static int prepare_sdp_description(FFStream *stream, uint8_t **pbuffer,
{
AVFormatContext *avc;
AVStream *avs = NULL;
AVOutputFormat *rtp_format = av_guess_format("rtp", NULL, NULL);
int i;
avc = avformat_alloc_context();
if (avc == NULL) {
if (avc == NULL || !rtp_format) {
return -1;
}
avc->oformat = rtp_format;
av_dict_set(&avc->metadata, "title",
stream->title[0] ? stream->title : "No Title", 0);
avc->nb_streams = stream->nb_streams;
......
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