From e60770679b5605e5af556d48aabd3789f63d2c96 Mon Sep 17 00:00:00 2001 From: Clément Bœsch Date: Sat, 20 Sep 2014 21:39:57 +0200 Subject: avformat/assenc: return correct error code --- libavformat/assenc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libavformat') diff --git a/libavformat/assenc.c b/libavformat/assenc.c index 2afeef7113..24833d2929 100644 --- a/libavformat/assenc.c +++ b/libavformat/assenc.c @@ -47,7 +47,7 @@ static int write_header(AVFormatContext *s) if (s->nb_streams != 1 || (avctx->codec_id != AV_CODEC_ID_SSA && avctx->codec_id != AV_CODEC_ID_ASS)) { av_log(s, AV_LOG_ERROR, "Exactly one ASS/SSA stream is needed.\n"); - return -1; + return AVERROR(EINVAL); } ass->write_ts = avctx->codec_id == AV_CODEC_ID_ASS; avpriv_set_pts_info(s->streams[0], 64, 1, 100); -- cgit v1.2.3