httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject Re: [PATCH] Take 2: Line Numbers are counted wrong in config file parsing
Date Wed, 22 Oct 1997 16:23:47 GMT
I'd rather you passed the entire cmd_param structure to cfg_getline ... 
it's cheaper and allows easier future expansion (i.e. a gets callback). 

Dean

On Wed, 22 Oct 1997, Martin Kraemer wrote:

> On Wed, Oct 22, 1997 at 01:17:32PM +0200, Martin Kraemer wrote:
> > I always wondered why the line numbers printed in error messages for
> > config file errors were often too low. (Syntax error on line ...)
> > 
> > Now I dug into the code and noted that the line counter is only
> > incremented in handle_directive(), but not in cfg_getline(); some lines
> > (notably those skipped by <IfModule>) don't go thru handle_directive()
> > and are therefore not counted.
> 
> I now added the line counting to cfg_getline() (where the '\n' is detected
> in the first place), but that required an interface change.
> 
> The following patch should count the config file's lines correctly.
> 
>     Martin
> -- 
> | S I E M E N S |  <Martin.Kraemer@mch.sni.de>  |      Siemens Nixdorf
> | ------------- |   Voice: +49-89-636-46021     |  Informationssysteme AG
> | N I X D O R F |   FAX:   +49-89-636-44994     |   81730 Munich, Germany
> ~~~~~~~~~~~~~~~~My opinions only, of course; pgp key available on request
> 

Mime
View raw message