From 30858e3b9b12500825a5dc4cd67902c3201c1b25 Mon Sep 17 00:00:00 2001 From: Simon Kelley Date: Mon, 9 Oct 2017 22:36:11 +0100 Subject: [PATCH] Spaces in CNAME options break parsing. cname = wibble,wobble works, but cname = wibble, wobble fails. Bug introduced in 2.77. commit a1d973f987e392870ba42a7e9d4d3cd166879ea0 --- CHANGELOG | 5 +++++ src/option.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG b/CHANGELOG index 075fe1a..6bb566d 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,8 @@ +version 2.79 + Fix parsing of CNAME arguments, which are confused by extra spaces. + Thanks to Diego Aguirre for spotting the bug. + + version 2.78 Fix logic of appending "." to PXE basename. Thanks to Chris Novakovic for the patch. diff --git a/src/option.c b/src/option.c index f4d22a2..0698dd3 100644 --- a/src/option.c +++ b/src/option.c @@ -3862,7 +3862,7 @@ err: new->target = target; new->ttl = ttl; - arg += strlen(arg)+1; + for (arg += strlen(arg)+1; *arg == ' '; arg++); } break;