diff options
author | Glenn Strauss <gstrauss@gluelogic.com> | 2021-08-31 02:48:16 -0400 |
---|---|---|
committer | Glenn Strauss <gstrauss@gluelogic.com> | 2021-09-08 15:06:07 -0400 |
commit | e77bc3995c6478ca02ecf5070b5c791f31bd3eed (patch) | |
tree | bc3571b7c49640dd5b1834f6a8d841060749ee5c /src/gw_backend.c | |
parent | 90978eb80889fbc149ac3cc533ed23ccb68cb0ce (diff) | |
download | lighttpd-git-e77bc3995c6478ca02ecf5070b5c791f31bd3eed.tar.gz |
[core] reduce wait time in gw_spawn_connection()
reduce wait time in gw_spawn_connection() from 10ms down to 1ms.
That is still plenty of time to detect immediate execve()/clone()
failures.
Diffstat (limited to 'src/gw_backend.c')
-rw-r--r-- | src/gw_backend.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gw_backend.c b/src/gw_backend.c index 05703aa6..631aca9b 100644 --- a/src/gw_backend.c +++ b/src/gw_backend.c @@ -501,7 +501,6 @@ __attribute_cold__ static int gw_spawn_connection(gw_host * const host, gw_proc * const proc, log_error_st * const errh, int debug) { int gw_fd; int status; - struct timeval tv = { 0, 10 * 1000 }; if (debug) { log_error(errh, __FILE__, __LINE__, @@ -642,6 +641,7 @@ static int gw_spawn_connection(gw_host * const host, gw_proc * const proc, log_e proc->is_local = 1; /* wait */ + struct timeval tv = { 0, 1000 }; select(0, NULL, NULL, NULL, &tv); if (0 != gw_proc_waitpid(host, proc, errh)) { |