mirror of
git://sourceware.org/git/glibc.git
synced 2024-11-21 01:12:26 +08:00
io: Add fsync call in tst-stat
io/tst-stat and io/tst-stat-lfs fail sporadically on the Fedora builders, and this change hopefully helps to avoid the issue.
This commit is contained in:
parent
73fc4e28b9
commit
ae13228409
@ -69,6 +69,10 @@ do_test (void)
|
||||
TEST_VERIFY_EXIT (fd >= 0);
|
||||
support_write_file_string (path, "abc");
|
||||
|
||||
/* This should help to prevent delayed allocation, which may result
|
||||
in a spurious stx_blocks/st_blocks difference. */
|
||||
fsync (fd);
|
||||
|
||||
bool check_ns = support_stat_nanoseconds (path);
|
||||
if (!check_ns)
|
||||
printf ("warning: timestamp with nanoseconds not supported\n");
|
||||
|
Loading…
Reference in New Issue
Block a user