aio_fsync: wait until aio_fsync completes
This patch introduces wait so that testcases exit doesn't race
with completion of aio_fsync.
This is to avoid SIGSEGV:
#0 0x000003fffd1f4a24 in _IO_flush_all_lockp () at genops.c:850
#1 0x000003fffd1f4b8e in _IO_cleanup () at genops.c:1010
#2 0x000003fffd1a88f6 in __run_exit_handlers () at exit.c:90
#3 0x000003fffd1a89b0 in __GI_exit () at exit.c:99
#4 0x000003fffd18c822 in __libc_start_main () at libc-start.c:292
#5 0x0000000080000b76 in _start ()
Signed-off-by: Jan Stancek <jstancek@redhat.com>
Acked-by: Cyril Hrubis <chrubis@suse.cz>
Reviewed-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
5 files changed