httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From stodd...@locus.apache.org
Subject cvs commit: apache-1.3/src/os/win32 service.c
Date Mon, 13 Mar 2000 21:05:38 GMT
stoddard    00/03/13 13:05:37

  Modified:    src/os/win32 service.c
  Log:
  Modules which load third-party DLLs (ala mod_dav)
  expect them to be in the path or cwd.  Tweak the
  service startup code to not only change to correct
  drive but also correct directory.
  
  Submitted by:	Keith Wannamaker
  Reviewed by:	Bill Stoddard
  
  Revision  Changes    Path
  1.15      +5 -3      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.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- service.c	2000/03/13 21:00:41	1.14
  +++ service.c	2000/03/13 21:05:36	1.15
  @@ -59,10 +59,12 @@
   
   void service_cd()
   {
  -    /* change to the drive with the executable */
  -    char buf[300];
  +    /* change to the drive and directory with the executable */
  +    char buf[300], *p;
       GetModuleFileName(NULL, buf, 300);
  -    buf[2] = 0;
  +    p = strrchr(buf, '\\');
  +    if (p != NULL)
  +        *p = 0;
       chdir(buf);
   }
   
  
  
  

Mime
View raw message