httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject Re: SERVER_VERSION
Date Thu, 16 Apr 1998 04:50:57 GMT
On Wed, 15 Apr 1998, Alexei Kosut wrote:

> +#ifdef SERVER_OS_TYPE
> +#define SERVER_OS_COMMENT " (" SERVER_OS_TYPE ")"
> +    if (r->server->send_os_type)
> +	ap_send_header_field(r, "Server", ap_pstrcat(r->pool, ap_get_server_version(),
> +						  SERVER_OS_COMMENT, NULL));
> +    else
> +#endif
> +	ap_send_header_field(r, "Server", ap_get_server_version());

You're allocating and copying a server string (possibly huge with all the
qualifiers like Apache/x.y.z mod_perl/a.b.c mod_php/m.n.o ...) just to
tack on a few letters.  This is all compile time constant.  If you're
going to make this crud an option then please push it all the way into
ap_get_server_version() and return one of two constant strings.

Dean



Mime
View raw message