From 75c97cfd449b2bac8e61af1017a83bdf43f5e8fe Mon Sep 17 00:00:00 2001 From: Samuel Mendoza-Jonas Date: Wed, 14 Dec 2016 14:44:23 +1100 Subject: discover: Maintain a backlog of status updates Add status updates to a persistent list in the discover_server struct, and send each client the backlog on connect. This avoids clients missing useful messages from early init. Clients will only show this in the backlog screen to avoid flooding the client's status line. Signed-off-by: Samuel Mendoza-Jonas --- discover/device-handler.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'discover/device-handler.c') diff --git a/discover/device-handler.c b/discover/device-handler.c index a73a7ce..48bfa0e 100644 --- a/discover/device-handler.c +++ b/discover/device-handler.c @@ -442,6 +442,7 @@ static void _device_handler_vstatus(struct device_handler *handler, status.type = type; status.message = talloc_vasprintf(handler, fmt, ap); + status.backlog = false; device_handler_status(handler, &status); @@ -617,6 +618,7 @@ static void countdown_status(struct device_handler *handler, status.type = STATUS_INFO; status.message = talloc_asprintf(handler, _("Booting in %d sec: %s"), sec, opt->option->name); + status.backlog = false; device_handler_status(handler, &status); -- cgit v1.2.1