W3C home > Mailing lists > Public > html-tidy@w3.org > October to December 1999

Re: Question about config.c

From: Dave Raggett <dsr@w3.org>
Date: Mon, 18 Oct 1999 14:56:10 +0100 (GMT Daylight Time)
To: Terry Teague <teague@mailandnews.com>
cc: html-tidy@w3.org
Message-ID: <Pine.WNT.4.10.9910181454540.900-100000@OEMCOMPUTER>
On Mon, 18 Oct 1999, Terry Teague wrote:

> Dear Dave,
> 
> Am I correct in assuming that ParseConfigFile() in config.c is
> designed to handle only the first Config file specified,
> regardless of how many times ParseConfigFile() is called? - i.e.
> in the base "tidy" code, there are 3 ways of parsing a Config
> file - if conditionally compiled, if environment variable set,
> if specified in command line.
> 
> I make this assumption on behaviour I observed while debugging
> my code - specifically once an EOF has been read for a Config
> file, no further Config files will be processed, because the
> static variable 'c' is set to EOF after parsing the first Config
> file, and AdvanceChar just returns EOF thereafter for all calls
> to ParseConfigFile().
> 
> If my assumption is incorrect, and this is not the intended
> behaviour, you might want to make the same change I made.
> Specifically after line 334 (27 Sep 99 version of Tidy), add :
> 
> 	c = '\0';

My intention was to allow multiple config files to be cascaded,
so thanks for spotting this problem.

Regards,

-- Dave Raggett <dsr@w3.org> http://www.w3.org/People/Raggett
phone: +44 122 578 2984 (or 2521) +44 385 320 444 (gsm mobile)
World Wide Web Consortium (on assignment from HP Labs)
Received on Monday, 18 October 1999 09:54:16 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 April 2012 06:13:42 GMT