syscalls/getdents01: Add close() and open() at the end of run()
PATCH 1/1 syscalls/getdents01: Add close() and open() at the end of run()
Hi Cyril,
I have re-submitted the patch according you review, please see: https://patchwork.ozlabs.org/project/ltp/patch/[email protected]/
Thanks so much!
Best Regards,
Gongyi
Quoted 26 lines
Hi!
Quoted 9 lines
testcases/kernel/syscalls/getdents/getdents01.c | 3 +++ 1 file changed, 3 insertions(+)testcases/kernel/syscalls/getdents/getdents01.c +0
-0testcases/kernel/syscalls/getdents/getdents01.c static void run(void) · line 98
Quoted 7 lines
testcases/kernel/syscalls/getdents/getdents01.c +3
-0@@ -92,6 +92,9 @@ static void run(void) }while (rval >0 );check_flags (); + +SAFE_CLOSE (fd); + fd =SAFE_OPEN ("." ,O_RDONLY |O_DIRECTORY ); }Good catch but I guess that it would be a bit cleaner if we opened the fd at the start of the
run()and closed it at the end instead of opening it insetup()and reopening it for each iteration.--
Cyril Hrubis
[email protected]