httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: Global data is evil :)
Date Wed, 09 Aug 2000 03:01:33 GMT

> On Mon, 7 Aug 2000, William A. Rowe, Jr. wrote:
> Does anyone object to this untested (but compiling) revision?

>> rbb writes...
>> Yes, I object.  That getopt code was being used because it was from
>> FreeBSD.  We were trying to avoid using a standard function name and then
>> having it behave in a completely unexpected way. 

> William Wrowe wrote...
> Any further comments before I scrap this proposal?

Yes... KEEP the multi-thread changes. They are goodness.

The thread-safe changes do not make the 'standard function name'
'behave in a completely unexpected way'.

It will work the same as it always has... only now it's thread safe.
I don't see why anyone should object to that. It's not like taking
sprintf ( ) and either adding parameters or making it convert
all formatted prints to uppercase or something weird like that.

Also... even if the 'getopt' code came from FreeBSD... so what?

Expecting the code to remain 'untouched' is like expecting
every implementation of sprintf ( ) or strcat ( ) to be the exact
same code all the time. Doesn't matter. What matters is that
the call does what it is supposed to and does it correctly
for the system it's used on. That's all that's happening here.

Who among us hasn't used 'undef' and 'define' to re-do
a library call when it needed to 'act' the same but do it in
a slightly different way? It's SOP.

It would be BETTER for Apache if the 'getopt()' that's used
is multi-threaded or at least doesn't always 'assume' that
main can never be called twice on the same process ID.

Kevin Kiley
CTO, Remote Communications, Inc. - Online Internet Content Compression Server.

View raw message