mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-02-17 17:02:45 +08:00
Correct the usleep calculation in fish_test_helper
'fish_test_helper print_pid_then_sleep' tried to sleep for .5 seconds, but instead it divided by .5 so it actually slept for 2 seconds. This exceeds the maximum value on NetBSD so it wasn't sleeping at all there. Fixes #6476
This commit is contained in:
parent
cc7618985a
commit
e0cdea9bb6
|
@ -50,7 +50,7 @@ static void print_stdout_stderr() {
|
|||
static void print_pid_then_sleep() {
|
||||
fprintf(stdout, "%d\n", getpid());
|
||||
fflush(nullptr);
|
||||
usleep(1000000 / .5); //.5 secs
|
||||
usleep(1000000 / 2); //.5 secs
|
||||
}
|
||||
|
||||
static void print_pgrp() { fprintf(stdout, "%d\n", getpgrp()); }
|
||||
|
|
Loading…
Reference in New Issue
Block a user