httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Bloom <>
Subject Re: cvs commit: apache-2.0/src/os/win32 main_win32.c
Date Mon, 20 Dec 1999 14:18:58 GMT

> On the larger topic of keeping the windows cruft out of http_main.c... I
> have pursued this main_win32 project precisely because most of the group
> wanted to keep the Windows code out of http_main.c. I somewhat agree with
> this direction, as long at it does not significantly impact the
> maintainability and reliability of the Windows port.  I've made good
> progress, but I'm not convinced it is ultimately the right thing to do. Take
> a look at what I've done (yes it has warts) and give me some feedback.

I think the goal of keeping all of the windows cruft out of http_main.c is
the wrong goal.  The correct goal should be to keep MOST of the cruft out.
I still like the solution I originally proposed.  Namely,  create a couple
of functions in the main_win32 project that do all of the dirty work, and
call those functions in the appropriate places from http_main.c, ifdef'ing
them out on non-win32 platforms.

I envision this:

win32_main project:

void server_restart(char *pidfilename) {



c = ap_getopt(...)
   switch (c)
#ifdef WIN32
    case 'k':
    case ...

This seems to keep all but a few lines out of the main-line code, but
leaves us with the most flexability for the server.  It doesn't really
even impact the readability of the code.


Ryan Bloom
4205 S Miami Blvd	
RTP, NC 27709		

Come to the first official Apache Software Foundation
Conference!  <http://ApacheCon.Com/>

View raw message