diff options
author | pommicket <pommicket@gmail.com> | 2025-06-15 23:43:03 -0400 |
---|---|---|
committer | pommicket <pommicket@gmail.com> | 2025-06-15 23:43:23 -0400 |
commit | 21eb7b3790b843b7e4db6c2ac2acedbb5c78eee5 (patch) | |
tree | 6b33a98d0edbc0e4084a54056d5ae5a4b754f2ab /os.h | |
parent | 100a4286688d6627698f857333a37ddec1f12d4a (diff) |
block until whatever program is writing the file finishes
Diffstat (limited to 'os.h')
-rw-r--r-- | os.h | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -85,6 +85,11 @@ static double time_get_seconds(void) { + (double)t.tv_nsec * 1e-9; } +static void time_sleep_ms(double ms) { + if (ms <= 0) return; + time_sleep_ns((u64)(ms * 1000000)); +} + /// sleep for seconds static void time_sleep_seconds(double s) { if (s <= 0) return; |