summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDavid Young <dyoung@hdfgroup.org>2022-03-08 23:24:11 (GMT)
committerDavid Young <dyoung@hdfgroup.org>2022-03-08 23:24:11 (GMT)
commit598a437e7d0d184e9db0ed590c0cb7e81b24a4df (patch)
treebe0f176df6f95d7d10124f38d36cd73230ba8300 /test
parent05d9fee16ee584695d8cf806da4319fda7e4ff72 (diff)
downloadhdf5-598a437e7d0d184e9db0ed590c0cb7e81b24a4df.zip
hdf5-598a437e7d0d184e9db0ed590c0cb7e81b24a4df.tar.gz
hdf5-598a437e7d0d184e9db0ed590c0cb7e81b24a4df.tar.bz2
sleep(3) is a POSIX function, not a C99 one. Switch all sleep()s back
to HDsleep().
Diffstat (limited to 'test')
-rw-r--r--test/flushrefresh.c2
-rw-r--r--test/swmr_reader.c2
-rw-r--r--test/swmr_remove_reader.c2
-rw-r--r--test/swmr_sparse_reader.c2
-rw-r--r--test/ttsafe_cancel.c4
-rw-r--r--test/use_common.c2
6 files changed, 7 insertions, 7 deletions
diff --git a/test/flushrefresh.c b/test/flushrefresh.c
index beb2e73..2743338 100644
--- a/test/flushrefresh.c
+++ b/test/flushrefresh.c
@@ -1337,7 +1337,7 @@ refresh_verification(const char *obj_pathname)
}
if (tries == sleep_tries)
- sleep(1);
+ HDsleep(1);
} while (--tries);
diff --git a/test/swmr_reader.c b/test/swmr_reader.c
index 5bb81129..602df21 100644
--- a/test/swmr_reader.c
+++ b/test/swmr_reader.c
@@ -334,7 +334,7 @@ read_records(const char *filename, hbool_t verbose, FILE *verbose_file, unsigned
return -1;
/* Sleep for the appropriate # of seconds */
- sleep(poll_time);
+ HDsleep(poll_time);
/* Retrieve the current time */
curr_time = HDtime(NULL);
diff --git a/test/swmr_remove_reader.c b/test/swmr_remove_reader.c
index b8afccf..4c27891 100644
--- a/test/swmr_remove_reader.c
+++ b/test/swmr_remove_reader.c
@@ -320,7 +320,7 @@ read_records(const char *filename, unsigned verbose, unsigned long nseconds, uns
return -1;
/* Sleep for the appropriate # of seconds */
- sleep(poll_time);
+ HDsleep(poll_time);
/* Retrieve the current time */
curr_time = HDtime(NULL);
diff --git a/test/swmr_sparse_reader.c b/test/swmr_sparse_reader.c
index 19c07ad..ccf5e4a 100644
--- a/test/swmr_sparse_reader.c
+++ b/test/swmr_sparse_reader.c
@@ -264,7 +264,7 @@ read_records(const char *filename, unsigned verbose, unsigned long nrecords, uns
} /* end if */
/* Pause */
- sleep(poll_time);
+ HDsleep(poll_time);
/* Retrieve and print the collection of metadata read retries */
if (print_metadata_retries_info(fid) < 0)
diff --git a/test/ttsafe_cancel.c b/test/ttsafe_cancel.c
index 24605bb..f191a25 100644
--- a/test/ttsafe_cancel.c
+++ b/test/ttsafe_cancel.c
@@ -151,7 +151,7 @@ tts_cancel_thread(void H5_ATTR_UNUSED *arg)
status = H5Diterate(&buffer, H5T_NATIVE_INT, dataspace, tts_cancel_callback, &dataset);
CHECK(status, FAIL, "H5Diterate");
- sleep(3);
+ HDsleep(3);
datavalue = 100;
status = H5Dwrite(dataset, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, &datavalue);
@@ -182,7 +182,7 @@ tts_cancel_callback(void *elem, hid_t H5_ATTR_UNUSED type_id, unsigned H5_ATTR_U
herr_t status;
tts_cancel_barrier();
- sleep(3);
+ HDsleep(3);
if (value != 1) {
TestErrPrintf("Error! Element value should be 1 and not %d\n", value);
diff --git a/test/use_common.c b/test/use_common.c
index cb22b08..3a710fa 100644
--- a/test/use_common.c
+++ b/test/use_common.c
@@ -558,7 +558,7 @@ read_uc_file(hbool_t towait, options_t *opts)
}
loops_waiting_for_plane++;
/* pause for a second */
- sleep(1);
+ HDsleep(1);
}
for (nplane = nplanes_seen; nplane < dims[0]; nplane++) {