httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wr...@locus.apache.org
Subject cvs commit: apache-1.3/src/os/win32 service.c
Date Thu, 16 Nov 2000 22:20:25 GMT
wrowe       00/11/16 14:20:25

  Modified:    src/os/win32 service.c
  Log:
    Beyond documentation of some existing issues, this patch corrects the
    status messages displayed when starting and restarting Apache as a
    service on Win9x.
  
  Revision  Changes    Path
  1.26      +14 -5     apache-1.3/src/os/win32/service.c
  
  Index: service.c
  ===================================================================
  RCS file: /home/cvs/apache-1.3/src/os/win32/service.c,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- service.c	2000/07/28 18:30:12	1.25
  +++ service.c	2000/11/16 22:20:25	1.26
  @@ -165,8 +165,8 @@
   
   DWORD WINAPI WatchWindow(void *service_name)
   {
  -    /* When running as a service under Windows 9x, there is no console
  -     * window present, and no ConsoleCtrlHandler to call when the system 
  +    /* When running as a service under Windows 9x, ConsoleCtrlHandler 
  +     * does not respond properly when the user logs off or the system 
        * is shutdown.  If the WatchWindow thread is created with a NULL
        * service_name argument, then the ...SystemMonitor window class is
        * used to create the "Apache" window to watch for logoff and shutdown.
  @@ -262,7 +262,10 @@
       /* Prevent holding open the (nonexistant) console */
       real_exit_code = 0;
   
  -    /* Hide the console */
  +    /* Hide the console of this Apache parent process
  +     * (children must have a parent in order to properly execute
  +     * 16-bit CGI processes or they will lock.)
  +     */
       FreeConsole();
   
       thread = CreateThread(NULL, 0, WatchWindow, (LPVOID) service_name, 0, 
  @@ -961,9 +964,15 @@
                   if (action == restart) 
                   {
                       if (globdat.ssStatus.dwCurrentState == SERVICE_STOPPED) 
  +                    {
  +                        printf("The %s service has %s.\n", display_name, 
  +                               past[action]);
                           strcpy(sig, "start");
  -                    else
  -                        ap_start_restart(1);
  +                        return status;
  +                    }
  +                    
  +                    ap_start_restart(1);
  +                    success = TRUE;
                   }
               }
           }
  
  
  

Mime
View raw message