aboutsummaryrefslogtreecommitdiff
path: root/server.c
diff options
context:
space:
mode:
authorOmar Polo <op@omarpolo.com>2021-06-12 13:41:33 +0000
committerOmar Polo <op@omarpolo.com>2021-06-12 13:41:33 +0000
commit89c88caa3c023d5194e0d572ae99ab006557cbf3 (patch)
tree6c86f9509bb217b524f3ae01c98dc04765394169 /server.c
parente18b070da8296bb0d5e30c8211aba43cb038d427 (diff)
mark backend as FCGI_READY when getting a fd
otherwise clients will remain stuck waiting for a pending request that doesn't exist (see apply_fastcgi switch.)
Diffstat (limited to 'server.c')
-rw-r--r--server.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/server.c b/server.c
index 514782b..7172f30 100644
--- a/server.c
+++ b/server.c
@@ -1220,6 +1220,7 @@ handle_imsg_fcgi_fd(struct imsgbuf *ibuf, struct imsg *imsg, size_t len)
f = &fcgi[id];
if ((f->fd = imsg->fd) != -1) {
+ f->s = FCGI_READY;
event_set(&f->e, imsg->fd, EV_READ | EV_PERSIST, &handle_fcgi,
&fcgi[id]);
event_add(&f->e, NULL);