From: Ian Campbell Subject: Re: [PATCH 08/14] libxl: disks: new xlu_disk_parse function Date: Fri, 13 May 2011 11:48:26 +0100 Message-ID: <1305283706.31488.88.camel@zakaz.uk.xensource.com> References: <1305211004-31687-1-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-2-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-3-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-4-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-5-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-6-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-7-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-8-git-send-email-ian.jackson@eu.citrix.com> <1305211004-31687-9-git-send-email-ian.jackson@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1305211004-31687-9-git-send-email-ian.jackson@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Ian Jackson Cc: "xen-devel@lists.xensource.com" , Ian Jackson List-Id: xen-devel@lists.xenproject.org On Thu, 2011-05-12 at 15:36 +0100, Ian Jackson wrote: > [...] > +void xlu__disk_err(DiskParseContext *dpc, const char *erroneous, > + const char *message) { > + fprintf(dpc->cfg->report, > + "%s: config parsing error in disk specification: %s" > + "%s%s%s" > + " in `%s'\n", > + dpc->cfg->filename, message, > + erroneous?": near `":"", erroneous?erroneous:"", erroneous?"'":"", > + dpc->spec); Something seems to be up with the leading whitespace here. [...] > + * Normally one would pass nspecs==1 and only specs[0]. But it is > + * permitted to pass more strings in which case each is parsed as a > + * string containing a collection of parameters (but they all refer > + * to of the configuration for a single disk). ^^ what is that doing there? I don't really speak enough flex to have a proper opinion but it looks plausible enough to me so: Acked-by: Ian Campbell This is the third time this week I've wondered if a patch ought to come along with a library of test inputs and expected outputs. I'll be proposing we switch to the waterfall model before you know it...