X-Git-Url: https://git.ozlabs.org/?p=petitboot;a=blobdiff_plain;f=lib%2Fpb-config%2Fpb-config.c;h=7fa925c216b8992f2eb2803aa6ef662c43d33c6c;hp=581d70f08cb8f65a4c680e77e7512366fc640e7a;hb=e3f78333a2a16760d6a497b84329c103208e921e;hpb=662129afba2d344d692a9dbfd430c91eff4f281d diff --git a/lib/pb-config/pb-config.c b/lib/pb-config/pb-config.c index 581d70f..7fa925c 100644 --- a/lib/pb-config/pb-config.c +++ b/lib/pb-config/pb-config.c @@ -63,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); @@ -83,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);