summaryrefslogtreecommitdiffstats
path: root/ui/ncurses/nc-cui.h
diff options
context:
space:
mode:
authorSamuel Mendoza-Jonas <sam@mendozajonas.com>2016-05-02 13:18:39 +1000
committerSamuel Mendoza-Jonas <sam@mendozajonas.com>2016-05-06 13:57:09 +1000
commitbbaa3ac16e14b1f386d70d14f16d0164d163017e (patch)
tree3d0929402f9f2175fe00e1f12a348eafcb136c12 /ui/ncurses/nc-cui.h
parent1949b1f0f990c7ab171339e20731fe6b17c92d8f (diff)
downloadtalos-petitboot-bbaa3ac16e14b1f386d70d14f16d0164d163017e.tar.gz
talos-petitboot-bbaa3ac16e14b1f386d70d14f16d0164d163017e.zip
ui/ncurses: Start UI before connected to server
If petitboot-nc starts before the discover server it will try to connect for a short while waiting for the server to appear. However in some scenarios the server can take longer than expected to come up, for example if the kernel is compiled with modules and the system has many disks, and the process will timeout and exit before the server is ready. The UI does not appear during this time so it can appear as if Petitboot failed to start at all. Change the default behaviour to start the UI first, and then wait for the server to appear. The UI will not timeout in this mode. The "--timeout" option is added to start with the old behaviour. Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com>
Diffstat (limited to 'ui/ncurses/nc-cui.h')
-rw-r--r--ui/ncurses/nc-cui.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/ncurses/nc-cui.h b/ui/ncurses/nc-cui.h
index afdb3c8..b00d251 100644
--- a/ui/ncurses/nc-cui.h
+++ b/ui/ncurses/nc-cui.h
@@ -72,7 +72,7 @@ struct cui {
struct cui *cui_init(void* platform_info,
int (*js_map)(const struct js_event *e),
- int start_daemon);
+ int start_daemon, int timeout);
struct nc_scr *cui_set_current(struct cui *cui, struct nc_scr *scr);
int cui_run(struct cui *cui);
void cui_item_edit(struct pmenu_item *item);
OpenPOWER on IntegriCloud