2 Commits

Author SHA1 Message Date
Thomas Wood
2442f595d2 lib/tests: explicitly raise SIGSEGV
Dereferencing a NULL pointer is undefined behaviour and may not always
result in a segmentation fault. Explicitly raise the SIGSEGV signal to
test handling of this signal.

v2: include signal.h (Derek Morton)

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
2015-09-24 14:23:44 +01:00
Derek Morton
a5633c406c lib/tests/igt_segfault Add unit test to test segfault handling
Unit test to check a segfaulting subtest is handled correctly.

v2: Added script to check subtest results
v3: Removed script. Updated test to use fork to monitor return status.
v4: Added igt_segfault to .gitignore

Signed-off-by: Derek Morton <derek.j.morton@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2015-06-15 15:45:55 +02:00