Re: [FFmpeg-devel] [PATCH] libavdevice/v4l2: fix invalid access to struct v4l2_buffer

2017-09-23 Thread Michael Niedermayer
On Wed, Sep 20, 2017 at 03:14:54PM +0200, Jaroslav Beran wrote: > In case we are short of queued buffers, at first v4l2_buffer was enqueued to > kernel so it's not owned by > user-space anymore. After that it's timestamp field was read, but it might be > overwritten by driver at > that moment. It

[FFmpeg-devel] [PATCH] libavdevice/v4l2: fix invalid access to struct v4l2_buffer

2017-09-21 Thread Jaroslav Beran
In case we are short of queued buffers, at first v4l2_buffer was enqueued to kernel so it's not owned by user-space anymore. After that it's timestamp field was read, but it might be overwritten by driver at that moment. It resulted in invalid timestamp sometimes. --- libavdevice/v4l2.c | 5