[PATCH 4/8] lib/igt.cocci: Convert abort() to igt_fail

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



abort should only be used for internal library checks - using
abort() we get a "crash" result, using igt_fail we get "fail"
in piglit.

Signed-off-by: Daniel Vetter <daniel.vetter@xxxxxxxx>
---
 lib/igt.cocci | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/lib/igt.cocci b/lib/igt.cocci
index 97aa43f9f057..dcb7bbc94dd0 100644
--- a/lib/igt.cocci
+++ b/lib/igt.cocci
@@ -44,3 +44,10 @@ expression list[n] Ep;
 @@
 -printf(Ep);
 +igt_info(Ep);
+
+// No abort for tests, really. Should only be used for internal library checks
+// in lib/*
+@@
+@@
+-abort();
++igt_fail(1);
-- 
2.0.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux