v4l2-compliance: fix s_std test: ENODATA is a valid error code.
authorHans Verkuil <hans.verkuil@cisco.com>
Tue, 19 Mar 2013 11:45:56 +0000 (12:45 +0100)
committerHans Verkuil <hans.verkuil@cisco.com>
Tue, 19 Mar 2013 11:45:56 +0000 (12:45 +0100)
The S_STD test failed because the driver returned ENODATA. This is a
valid error code, but the test didn't check for it.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
utils/v4l2-compliance/v4l2-test-io-config.cpp

index d1a555c..9ecfaa5 100644 (file)
@@ -61,7 +61,7 @@ static int checkStd(struct node *node, bool has_std, v4l2_std_id mask, bool is_i
                return fail("STD cap not set, but could still set a standard\n");
        std = V4L2_STD_ATSC;
        ret = doioctl(node, VIDIOC_S_STD, &std);
-       if (ret != EINVAL && ret != ENOTTY)
+       if (ret != ENODATA && ret != EINVAL && ret != ENOTTY)
                return fail("could set standard to ATSC, which is not supported anymore\n");
        for (i = 0; ; i++) {
                memset(&enumstd, 0xff, sizeof(enumstd));