httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brian Havard" <>
Subject Re: cvs commit: apache-2.0/src/modules/standard mod_asis.c mod_autoindex.c mod_log_config.c mod_negotiation.c
Date Sat, 11 Sep 1999 05:10:46 GMT
On Fri, 10 Sep 1999 22:32:20 -0500, Manoj Kasichainula wrote:

>On Sat, Sep 11, 1999 at 12:46:34PM +1000, Brian Havard wrote:
>> IMO ap_{get,put}_os_file() should not be allowed in non-platform specific
>> code. In fact I think we'd be better off if they didn't exist. If you can't
>> do what you need to do without resorting to using the OS handle directly then
>> you need to add an APR function to do the job, not hack into the guts of the
>> apr_file_t from the application.
>Two points of disagreement.
>1. The world is not an APRed world. At some point, Apache code has to
>be able to interact with third-party code that doesn't use APR. To do
>this, we have to have routines to convert back-and-forth

The problem is that different platforms use different types. Unix may always
use an int but OS/2 uses HFILE (an unsigned long) and Win32 uses HANDLE (a
void *), neither of which will make any 3rd party libs happy as they use
different 'handle space' to the unix style file descriptors.

It may be possible to map between OS file handles and unix-like (Posix?) file
descriptors but that's not what these functions do.

>2. The MPMs are examples of this. The MPMs will have platform-specific
>code. The really cool ones will probably have really cool
>platform-specific code. This code will have to interact with an APRed
>core. So conversion between APR and native types will be necessary.

MPMs I guess are ok to use them but if they're fully platform specific then
they may as well bypass APR altogether to do funky OS specific stuff.

 |  Brian Havard                 |  "He is not the messiah!                   |
 |  |  He's a very naughty boy!" - Life of Brian |

View raw message