httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Fritsch ...@sfritsch.de>
Subject Re: svn commit: r1204730 - in /httpd/httpd/branches/2.4.x: include/ap_expr.h include/ap_mmn.h server/util_expr_eval.c server/util_expr_parse.c server/util_expr_parse.y
Date Tue, 22 Nov 2011 20:58:31 GMT
On Tuesday 22 November 2011, William A. Rowe Jr. wrote:
> > +/*
> > + * To reduce counting overhead, we only count calls to
> > + * ap_expr_eval_word() and ap_expr_eval(). The max number of
> > + * stack frames is larger by some factor.
> > + */
> > +#define AP_EXPR_MAX_RECURSION   20
> > +static int inc_rec(ap_expr_eval_ctx_t *ctx)
> > +{
> > +    if (ctx->reclvl<  AP_EXPR_MAX_RECURSION) {
> > +        ctx->reclvl++;
> > +        return 0;
> > +    }
> > +    *ctx->err = "Recursion limit reached";
> > +    /* short circuit further evaluation */
> > +    ctx->reclvl = INT_MAX;
> 
> When did this project adopt Posix99?  Not that I'm complaining
> but that isn't a K&R construct (and this is the first such breakage
> that I'm aware of.)

I assume you refer to the INT_MAX? That's C89 according to Google. And 
yes, we want to support C89 (otherwise http_log.h could have been a 
lot simpler). And no, we don't want to support anything older than 
C89, IMNSHO.

Mime
View raw message