You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by wr...@apache.org on 2004/06/21 20:31:28 UTC

cvs commit: apache-1.3/src/modules/standard mod_rewrite.c

wrowe       2004/06/21 11:31:28

  Modified:    src/modules/standard mod_rewrite.c
  Log:
    Fix the rewrite_map program invocation for Win32.  Someone borrowed
    the pass-environ[][] construct from unix, but CreateProcess is much
    happier to copy the current environment when passed NULL for the
    flat environment strings argument (properly formatted, that argument
    must be null or a string in the format "var1=val\0var2=val\0\0".)
  
    The only other CreateProcess call which does *not* pass NULL for
    the envvars arg, in util_script.c for cgi, does the right thing
    in constructing that argument.
  
  Submitted by: Philip Gladstone [pgladstone cisco.com]
  
  Revision  Changes    Path
  1.194     +2 -2      apache-1.3/src/modules/standard/mod_rewrite.c
  
  Index: mod_rewrite.c
  ===================================================================
  RCS file: /home/cvs/apache-1.3/src/modules/standard/mod_rewrite.c,v
  retrieving revision 1.193
  retrieving revision 1.194
  diff -u -r1.193 -r1.194
  --- mod_rewrite.c	20 Feb 2004 20:38:27 -0000	1.193
  +++ mod_rewrite.c	21 Jun 2004 18:31:27 -0000	1.194
  @@ -3573,8 +3573,8 @@
           si.hStdOutput  = pinfo->hPipeOutputWrite;
           si.hStdError   = pinfo->hPipeErrorWrite;
   
  -        if (CreateProcess(NULL, pCommand, NULL, NULL, TRUE, 0,
  -                          environ, NULL, &si, &pi)) {
  +        if (CreateProcess(NULL, pCommand, NULL, NULL, TRUE, 0, 
  +                          NULL, NULL, &si, &pi)) {
               CloseHandle(pi.hProcess);
               CloseHandle(pi.hThread);
               child_pid = pi.dwProcessId;