1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

matroskadec: return more correct error code on read error.

This commit is contained in:
Anton Khirnov 2012-07-21 10:48:39 +02:00
parent a8a2271fe0
commit 721113bed2

View File

@ -597,8 +597,9 @@ static int ebml_read_num(MatroskaDemuxContext *matroska, AVIOContext *pb,
av_log(matroska->ctx, AV_LOG_ERROR,
"Read error at pos. %"PRIu64" (0x%"PRIx64")\n",
pos, pos);
return pb->error ? pb->error : AVERROR(EIO);
}
return AVERROR(EIO); /* EOS or actual I/O error */
return AVERROR_EOF;
}
/* get the length of the EBML number */