httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rodent of Unusual Size <Ken.C...@Golux.Com>
Subject Re: pr#4118: MSIE 4.0 screws up with Vary
Date Thu, 22 Apr 1999 00:26:57 GMT
Roy T. Fielding wrote:
> 
> Alternatively, we could fix table_merge so that the fields are split
> before merging, but that would have a significant performance hit.

Or how about

API_EXPORT(void) ap_add_unique_token(table *t, const char *key,
                                     const char *val)
{
    if (! ap_find_token(t->p, ap_table_get(t, key), val)) {
        ap_table_merge(t, key, val)
    }
}

This could be used for cases in which tokens shouldn't be
occur more than once in the string.  A little more overhead,
but an anlternative rather than a replacement for ap_table_merge().
The above is obviously only for HTTP tokens.

(Why does ap_find_token() take a pool * argument it doesn't use?)
-- 
#ken    P-)}

Ken Coar                    <http://Web.Golux.Com/coar/>
Apache Software Foundation  <http://www.apache.org/>
"Apache Server for Dummies" <http://Web.Golux.Com/coar/ASFD/>

Mime
View raw message