qcap: Fix compilation with older videodev2.h.

Older videodev2.h lack the V4L2_CAP_DEVICE_CAPS define and
the device_caps field in the v4l2_capability struct.

Signed-off-by: Martin Storsjo <martin@martin.st>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Martin Storsjo 2019-04-27 22:07:00 +03:00 committed by Alexandre Julliard
parent b10cdce31d
commit 2c42d5ee4d
1 changed files with 2 additions and 0 deletions

View File

@ -577,8 +577,10 @@ Capture * qcap_driver_init( IPin *pOut, USHORT card )
goto error;
}
#ifdef V4L2_CAP_DEVICE_CAPS
if (caps.capabilities & V4L2_CAP_DEVICE_CAPS)
caps.capabilities = caps.device_caps;
#endif
if (!(caps.capabilities & V4L2_CAP_VIDEO_CAPTURE))
{