[FFmpeg-devel] [PATCH 4/6] avcodec/v4l2_context: Use AVERROR macro

Andriy Gelman andriy.gelman at gmail.com
Mon Jan 13 06:11:28 EET 2020


From: Andriy Gelman <andriy.gelman at gmail.com>

Signed-off-by: Andriy Gelman <andriy.gelman at gmail.com>
---
 libavcodec/v4l2_context.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/v4l2_context.c b/libavcodec/v4l2_context.c
index d38ff732dbf..5b8d5f225cd 100644
--- a/libavcodec/v4l2_context.c
+++ b/libavcodec/v4l2_context.c
@@ -207,7 +207,7 @@ static int v4l2_handle_event(V4L2Context *ctx)
         ret = ff_v4l2_m2m_codec_full_reinit(s);
         if (ret) {
             av_log(logger(ctx), AV_LOG_ERROR, "v4l2_m2m_codec_full_reinit\n");
-            return -EINVAL;
+            return AVERROR(EINVAL);
         }
         goto reinit_run;
     }
@@ -221,7 +221,7 @@ static int v4l2_handle_event(V4L2Context *ctx)
         ret = ff_v4l2_m2m_codec_reinit(s);
         if (ret) {
             av_log(logger(ctx), AV_LOG_ERROR, "v4l2_m2m_codec_reinit\n");
-            return -EINVAL;
+            return AVERROR(EINVAL);
         }
         goto reinit_run;
     }
-- 
2.24.0



More information about the ffmpeg-devel mailing list