summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2013-07-04 15:25:51 +0800
committerJeremy Kerr <jk@ozlabs.org>2013-07-04 15:25:51 +0800
commit9d9f5fafe1ab15683601c03b14c35fe6a405ba45 (patch)
tree2c6b9d4394dc2ab8a4f6c7a993fcc8faf5f8e9e4
parentd2d7d2911c4d97edd31f6596365e6c5249768a99 (diff)
downloadtalos-petitboot-9d9f5fafe1ab15683601c03b14c35fe6a405ba45.tar.gz
talos-petitboot-9d9f5fafe1ab15683601c03b14c35fe6a405ba45.zip
discover/pxe-parser: All options are name <space> value pairs
Abort the pair parse if we don't have both a name and a value. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
-rw-r--r--discover/pxe-parser.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/discover/pxe-parser.c b/discover/pxe-parser.c
index c300b69..67cb788 100644
--- a/discover/pxe-parser.c
+++ b/discover/pxe-parser.c
@@ -21,6 +21,9 @@ static void pxe_process_pair(struct conf_context *ctx,
struct discover_boot_option *opt = ctx->parser_info;
struct pb_url *url;
+ if (!name)
+ return;
+
if (streq(name, "LABEL")) {
if (opt)
pxe_finish(ctx);
OpenPOWER on IntegriCloud