From 5314cebf5fe766bdca6c779e785b8dfaa3808142 Mon Sep 17 00:00:00 2001 From: Samuel Mendoza-Jonas Date: Thu, 23 Mar 2017 17:42:37 +1100 Subject: discover/paths: Add network jobs to queue Load tasks that start before the network is available will fail. Rather than just fail these tasks, add them to a queue that is processed once the network is ready. This helps users who try to request files early in setup, as well as very early running load tasks. Signed-off-by: Samuel Mendoza-Jonas --- discover/paths.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'discover/paths.h') diff --git a/discover/paths.h b/discover/paths.h index 35673b7..67fe8a3 100644 --- a/discover/paths.h +++ b/discover/paths.h @@ -43,6 +43,10 @@ struct load_url_result { */ typedef void (*load_url_complete)(struct load_url_result *result, void *data); +/* Start transfers that were waiting for network connectivity */ +void pending_network_jobs_start(void); +void pending_network_jobs_cancel(void); + /* Load a (potentially remote) file, and return a guaranteed-local name */ struct load_url_result *load_url_async(void *ctx, struct pb_url *url, load_url_complete complete, void *data, -- cgit v1.2.1