X-Git-Url: http://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=lib%2Fpb-config%2Fpb-config.c;h=7fa925c216b8992f2eb2803aa6ef662c43d33c6c;hp=52a43b1607dc8bbf1410569474b1bd9c786bf8d6;hb=98b04aa42a4f1dc8e585f00d75c3b28d9e9aa2a9;hpb=d19b94a83870f7b2a41e55d7462bcf36d2b5ba0b diff --git a/lib/pb-config/pb-config.c b/lib/pb-config/pb-config.c index 52a43b1..7fa925c 100644 --- a/lib/pb-config/pb-config.c +++ b/lib/pb-config/pb-config.c @@ -33,6 +33,7 @@ static struct interface_config *config_copy_interface(struct config *ctx, talloc_strdup(dest, src->static_config.url); break; } + dest->override = src->override; return dest; } @@ -62,6 +63,9 @@ struct config *config_copy(void *ctx, const struct config *src) dest->network.dns_servers[i] = talloc_strdup(dest, src->network.dns_servers[i]); + dest->http_proxy = talloc_strdup(dest, src->http_proxy); + dest->https_proxy = talloc_strdup(dest, src->https_proxy); + dest->n_autoboot_opts = src->n_autoboot_opts; dest->autoboot_opts = talloc_array(dest, struct autoboot_option, dest->n_autoboot_opts); @@ -82,15 +86,16 @@ struct config *config_copy(void *ctx, const struct config *src) dest->allow_writes = src->allow_writes; - dest->n_tty = src->n_tty; - if (src->tty_list) - dest->tty_list = talloc_array(dest, char *, src->n_tty); - for (i = 0; i < src->n_tty && src->n_tty; i++) - dest->tty_list[i] = talloc_strdup(dest->tty_list, - src->tty_list[i]); + dest->n_consoles = src->n_consoles; + if (src->consoles) + dest->consoles = talloc_array(dest, char *, src->n_consoles); + for (i = 0; i < src->n_consoles && src->n_consoles; i++) + dest->consoles[i] = talloc_strdup(dest->consoles, + src->consoles[i]); - if (src->boot_tty) - dest->boot_tty = talloc_strdup(dest, src->boot_tty); + if (src->boot_console) + dest->boot_console = talloc_strdup(dest, src->boot_console); + dest->manual_console = src->manual_console; if (src->lang && strlen(src->lang)) dest->lang = talloc_strdup(dest, src->lang);