]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: cli: wake up the CLI's task after a timeout update
authorWilly Tarreau <w@1wt.eu>
Thu, 24 Nov 2016 14:35:16 +0000 (15:35 +0100)
committerWilly Tarreau <w@1wt.eu>
Thu, 24 Nov 2016 14:35:16 +0000 (15:35 +0100)
When the CLI's timeout is reduced, nothing was done to take the task
up to update it. In the past it used to run inside process_stream()
so it used to be refreshed. This is not the case anymore since we have
the appctx so the task needs to be woken up in order to recompute the
new expiration date.

This fix needs to be backported to 1.6.

src/dumpstats.c

index fe1ad48dcb734f8274aff1b983d909ff7c0f6220..6525939a5477e196efb6ecad9ff0656dd54cdd54 100644 (file)
@@ -1849,6 +1849,7 @@ static int stats_sock_parse_request(struct stream_interface *si, char *line)
                                }
 
                                s->req.rto = s->res.wto = 1 + MS_TO_TICKS(timeout*1000);
+                               task_wakeup(s->task, TASK_WOKEN_MSG); // recompute timeouts
                                return 1;
                        }
                        else {