bjh         99/04/28 19:04:07

  Modified:    src/main alloc.c
  Log:
  When spawning OS/2 CGIs, prevent handles to parent's side of stdio pipes from
  being inherited by spawned child so pipes shut down when they should.
  
  Revision  Changes    Path
  1.110     +9 -0      apache-1.3/src/main/alloc.c
  
  Index: alloc.c
  ===================================================================
  RCS file: /home/cvs/apache-1.3/src/main/alloc.c,v
  retrieving revision 1.109
  retrieving revision 1.110
  diff -u -r1.109 -r1.110
  --- alloc.c   1999/04/27 20:36:30     1.109
  +++ alloc.c   1999/04/29 02:04:04     1.110
  @@ -68,6 +68,11 @@
   
   #include <stdarg.h>
   
  +#ifdef OS2
  +#define INCL_DOS
  +#include <os2.h>
  +#endif
  +
   /* debugging support, define this to enable code which helps detect re-use
    * of freed memory and other such nonsense.
    *
  @@ -2214,6 +2219,10 @@
               close(err_fds[1]);
           }
       
  +        DosSetFHState(in_fds[1], OPEN_FLAGS_NOINHERIT);
  +        DosSetFHState(out_fds[0], OPEN_FLAGS_NOINHERIT);
  +        DosSetFHState(err_fds[0], OPEN_FLAGS_NOINHERIT);
  +        
           pid = func(data, NULL);
       
           if ( pid )
  
  
  

Reply via email to