diff options
Diffstat (limited to 'tools/testing/selftests/mm/gup_longterm.c')
-rw-r--r-- | tools/testing/selftests/mm/gup_longterm.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/testing/selftests/mm/gup_longterm.c b/tools/testing/selftests/mm/gup_longterm.c index d33d3e68ff..ad168d35b2 100644 --- a/tools/testing/selftests/mm/gup_longterm.c +++ b/tools/testing/selftests/mm/gup_longterm.c @@ -265,10 +265,11 @@ static void run_with_tmpfile(test_fn fn, const char *desc) fd = fileno(file); if (fd < 0) { ksft_test_result_fail("fileno() failed\n"); - return; + goto close; } fn(fd, pagesize); +close: fclose(file); } |