httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brandon Long <>
Subject Re: fd leaks
Date Tue, 30 May 1995 04:35:26 GMT
Last time, Rob Hartill uttered the following other thing:
> Maybe if we just shifted all the global variables into a
> record which followed the current connection. If all the routines
> refer to the record instead of global variables, we'd be one step
> closer to having a reentrant server. Linked lists could be used
> to store dynamic info such as open file descriptors, environment
> varibles etc.

The only other option is to use specific file descriptors and
dup them for the necessary parts.  Kinda make reentrancy a problem.

1.4 isn't reentrant either, but its closer.  We'd have to get
rid of most of the globals, as well as look at some of the 
library functions (looking to see what was MT safe)
> How difficult would this be ? anyone have a feel for it ?
> All the routines would need a parameter to point to the current
> record. That looks like the biggest starting problem, but if all
> routines were changed to have the 1st param be the pointer, it could
> be implemented reasonably quickly. I'm willing to do that if it's
> worth the effort.
> thoughts ?

This is what I wanted to do for 1.5, but its kinda under a tight
schedule, so it might be 1.6 before I get to do it.  There are almost
no structures in the current server (mostly in what I would think 
were later sections of the code) and this causes a large number
of parameters, and makes it almost impossible to pass anything 
down a couple of levels without modifying all of the functions.

Maybe just adding the parameter first would be a logical and easy
first step.


 Brandon Long   (N9WUC)     "I think, therefore, I am confused." -- RAW
 Computer Engineering   	Run Linux '95.	It's that Easy. 
 University of Illinois
		Don't worry, these aren't even my views.

View raw message