X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=discover%2Fkboot-parser.c;h=025f13b6afa1bd8e32606da013f6dc2a15f4f667;hb=1f03bc43719c4cc787d5b7d3a756c532d39bfc26;hp=e688c22d512fde7bf91736ba7808f38fd52f3c4c;hpb=5472ed16df5642aedc124a1b49a35d99da98cc37;p=petitboot diff --git a/discover/kboot-parser.c b/discover/kboot-parser.c index e688c22..025f13b 100644 --- a/discover/kboot-parser.c +++ b/discover/kboot-parser.c @@ -21,6 +21,11 @@ static void kboot_process_pair(struct conf_context *conf, const char *name, const char *root; struct boot_option *opt; + /* fixup for bare values */ + + if (!name) + return; + if (conf_param_in_list(ignored_names, name)) return; @@ -133,10 +138,11 @@ static int kboot_parse(struct discover_context *dc) conf = talloc_zero(dc, struct conf_context); if (!conf) - return -1; + return 0; conf->dc = dc; conf->global_options = kboot_global_options, + conf_init_global_options(conf); conf->conf_files = kboot_conf_files, conf->process_pair = kboot_process_pair; conf->parser_info = (void *)kboot_ignored_names, @@ -147,4 +153,4 @@ static int kboot_parse(struct discover_context *dc) return rc; } -define_parser(kboot, 98, kboot_parse); +define_parser(kboot, kboot_parse);