Skip to contentSkip to conversation

v4l2-compliance: Remove spurious error messages

PATCH New Ezequiel Garcia 1 participant 1 message Nov 20, 2018 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 v4l2-compliance: Remove spurious error messages

Get rid of a couple confusing error messages, namely:

test VIDIOC_G_FMT: OK
fail: v4l2-test-formats.cpp(464): pix_mp.plane_fmt[0].reserved not zeroed
fail: v4l2-test-formats.cpp(752): Video Output Multiplanar is valid, but TRY_FMT failed to return a format
test VIDIOC_TRY_FMT: FAIL
fail: v4l2-test-formats.cpp(464): pix_mp.plane_fmt[0].reserved not zeroed
fail: v4l2-test-formats.cpp(1017): Video Output Multiplanar is valid, but no S_FMT was implemented
test VIDIOC_S_FMT: FAI

Where only the first message "pix_mp.plane_fmt[0].reserved not zeroed" is accurate.

---
 utils/v4l2-compliance/v4l2-test-formats.cpp | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
utils/v4l2-compliance/v4l2-test-formats.cpp +2 -4
index 2fb811ad5eb4..006cc3222c65 100644
@@ -748,8 +748,7 @@ int testTryFormats(struct node *node)
 		}
 		ret = testFormatsType(node, ret, type, fmt, true);
 		if (ret)
-			return fail("%s is valid, but TRY_FMT failed to return a format\n",
-					buftype2s(type).c_str());
+			return ret;
 	}
 
 	memset(&fmt, 0, sizeof(fmt));
@@ -1013,8 +1012,7 @@ int testSetFormats(struct node *node)
 		}
 		ret = testFormatsType(node, ret, type, fmt_set, true);
 		if (ret)
-			return fail("%s is valid, but no S_FMT was implemented\n",
-					buftype2s(type).c_str());
+			return ret;
 
 		fmt_set = fmt;
 		ret = doioctl(node, VIDIOC_S_FMT, &fmt_set);
Signature · 1 line
2.19.1