Browse Source

avcodec/v4l2_context: return {decoder,encoder}_cmd errors

Signed-off-by: Aman Gupta <aman@tmm1.net>
tags/n4.3
Aman Gupta 5 years ago
parent
commit
bad8365b2b
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      libavcodec/v4l2_context.c

+ 4
- 0
libavcodec/v4l2_context.c View File

@@ -226,6 +226,8 @@ static int v4l2_stop_decode(V4L2Context *ctx)
/* DECODER_CMD is optional */
if (errno == ENOTTY)
return ff_v4l2_context_set_status(ctx, VIDIOC_STREAMOFF);
else
return AVERROR(errno);
}

return 0;
@@ -244,6 +246,8 @@ static int v4l2_stop_encode(V4L2Context *ctx)
/* ENCODER_CMD is optional */
if (errno == ENOTTY)
return ff_v4l2_context_set_status(ctx, VIDIOC_STREAMOFF);
else
return AVERROR(errno);
}

return 0;


Loading…
Cancel
Save