diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2016-10-13 16:32:24 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2016-10-13 16:33:20 +0100 |
commit | dc27c73c7d0e146944fdb9bf680cd60eed503c99 (patch) | |
tree | 633000e5e6a6d0d1b064d2162b8af7d7fc09f01d /tests | |
parent | 764d66832640fbe6ae9d320073bd07c2af4de322 (diff) |
igt/gem_wait: munmap the batch along all paths
Move the munmap() to the common path to ensure it is released at the end
of each test.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/gem_wait.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/gem_wait.c b/tests/gem_wait.c index 0ecb92f4..b4127de8 100644 --- a/tests/gem_wait.c +++ b/tests/gem_wait.c @@ -169,7 +169,6 @@ static void basic(int fd, unsigned engine, unsigned flags) __sync_synchronize(); timeout = 1; } - munmap(batch, 4096); memset(&tv, 0, sizeof(tv)); while (__gem_wait(fd, &wait) == -ETIME) @@ -222,6 +221,7 @@ static void basic(int fd, unsigned engine, unsigned flags) } gem_close(fd, obj.handle); + munmap(batch, 4096); } igt_main |