summaryrefslogtreecommitdiff
path: root/tests/sw_sync.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2019-01-30 22:16:39 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2019-01-31 09:17:26 +0000
commit93c6b1ca84866fabe4601b1e93145209e4df1177 (patch)
tree4394129f23d49e1df622cc91473f72dd6b40a6e6 /tests/sw_sync.c
parent6f6bacf12759fb319ade3ba37861ae711f8a5cd9 (diff)
sw_sync: Initialise struct before use
sw_sync: ../lib/igt_core.c:1592: __igt_fork_helper: Assertion `!proc->running' Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108889 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Diffstat (limited to 'tests/sw_sync.c')
-rw-r--r--tests/sw_sync.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/sw_sync.c b/tests/sw_sync.c
index 207908ed..ac4caf8b 100644
--- a/tests/sw_sync.c
+++ b/tests/sw_sync.c
@@ -171,12 +171,11 @@ static void test_sync_busy(void)
static void test_sync_busy_fork_unixsocket(void)
{
+ struct igt_helper_process proc = {};
int fence;
int timeline;
int skip = 0;
int sv[2];
- struct igt_helper_process proc;
-
timeline = sw_sync_timeline_create();
fence = sw_sync_timeline_create_fence(timeline, 1);
@@ -258,10 +257,10 @@ out:
static void test_sync_busy_fork(void)
{
+ struct igt_helper_process proc = {};
int fence;
int timeline;
int skip = 0;
- struct igt_helper_process proc;
timeline = sw_sync_timeline_create();
fence = sw_sync_timeline_create_fence(timeline, 1);