Fixes Coverity "Unchecked return value" defects.

Signed-off-by: Vinson Lee <[email protected]>
---
 .../spec/ext_unpack_subimage/ext_unpack_subimage.c | 24 +++++++++++-----------
 1 file changed, 12 insertions(+), 12 deletions(-)

diff --git a/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c 
b/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c
index e65f4be..3935d92 100644
--- a/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c
+++ b/tests/spec/ext_unpack_subimage/ext_unpack_subimage.c
@@ -156,19 +156,19 @@ piglit_display(void)
                             0, 0, 1, 1);
 
        if (extension_supported) {
-               pass &= piglit_probe_pixel_rgba(piglit_width / 2,
-                                               piglit_height / 4,
-                                               blue);
-               pass &= piglit_probe_pixel_rgba(piglit_width / 2,
-                                               piglit_height * 3 / 4,
-                                               cyan);
+               pass = piglit_probe_pixel_rgba(piglit_width / 2,
+                                              piglit_height / 4,
+                                              blue) && pass;
+               pass = piglit_probe_pixel_rgba(piglit_width / 2,
+                                              piglit_height * 3 / 4,
+                                              cyan) && pass;
        } else {
-               pass &= piglit_probe_pixel_rgba(piglit_width / 2,
-                                               piglit_height / 4,
-                                               red);
-               pass &= piglit_probe_pixel_rgba(piglit_width / 2,
-                                               piglit_height * 3 / 4,
-                                               green);
+               pass = piglit_probe_pixel_rgba(piglit_width / 2,
+                                              piglit_height / 4,
+                                              red) && pass;
+               pass = piglit_probe_pixel_rgba(piglit_width / 2,
+                                              piglit_height * 3 / 4,
+                                              green) && pass;
        }
 
        return pass ? PIGLIT_PASS : PIGLIT_FAIL;
-- 
1.9.3

_______________________________________________
Piglit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to