Commit 1214ce83 authored by diego's avatar diego

Set AVSubtitle format to 0. Neither dvdsubdec nor xsubdec intializes format

to 0, but ffplay checks it before displaying subtitles (ffplay.c:1437).
patch by Björn Axelsson, gecko acc.umu se


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@17170 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 3a5654f7
......@@ -175,6 +175,7 @@ static int decode_dvd_subtitles(AVSubtitle *sub_header,
return -1;
sub_header->rects = NULL;
sub_header->num_rects = 0;
sub_header->format = 0;
sub_header->start_display_time = 0;
sub_header->end_display_time = 0;
......
......@@ -51,6 +51,8 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size,
int w, h, x, y, rlelen, i;
GetBitContext gb;
sub->format = 0;
// check that at least header fits
if (buf_size < 27 + 7 * 2 + 4 * 3) {
av_log(avctx, AV_LOG_ERROR, "coded frame too small\n");
......
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