diff options
author | Hennes Rohling <hro@openoffice.org> | 2001-07-23 14:20:15 +0000 |
---|---|---|
committer | Hennes Rohling <hro@openoffice.org> | 2001-07-23 14:20:15 +0000 |
commit | becc546a2034eb1ecf70d270f4b091404cbca99a (patch) | |
tree | e44709394198ad58f30c44f3f1b60ef863fce53f /sal/osl/w32/process.c | |
parent | d417ba821821426b976b9ec8187ff39b30e170a0 (diff) |
#88840# Use SECURITY_ATTRIBUTES to support real inheritance
Diffstat (limited to 'sal/osl/w32/process.c')
-rw-r--r-- | sal/osl/w32/process.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/sal/osl/w32/process.c b/sal/osl/w32/process.c index 69118f066b5a..77cb5aa3ddd0 100644 --- a/sal/osl/w32/process.c +++ b/sal/osl/w32/process.c @@ -2,9 +2,9 @@ * * $RCSfile: process.c,v $ * - * $Revision: 1.14 $ + * $Revision: 1.15 $ * - * last change: $Author: hro $ $Date: 2001-07-20 16:41:29 $ + * last change: $Author: hro $ $Date: 2001-07-23 15:20:15 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -168,6 +168,12 @@ oslProcessError SAL_CALL osl_executeProcess_WithRedirectedIO( HANDLE hInputRead = NULL, hInputWrite = NULL, hOutputRead = NULL, hOutputWrite = NULL, hErrorRead = NULL, hErrorWrite = NULL; BOOL fInheritHandles = FALSE; + SECURITY_ATTRIBUTES sa; + + /* Set up the security attributes struct. */ + sa.nLength= sizeof(SECURITY_ATTRIBUTES); + sa.lpSecurityDescriptor = NULL; + sa.bInheritHandle = TRUE; /* if no image name given, use first argument */ if( ( NULL == ustrImageName ) && nArguments ) @@ -293,7 +299,7 @@ oslProcessError SAL_CALL osl_executeProcess_WithRedirectedIO( { HANDLE hTemp = NULL; - CreatePipe( &hInputRead, &hTemp, NULL, 0 ); + CreatePipe( &hInputRead, &hTemp, &sa, 0 ); DuplicateHandle( GetCurrentProcess(), hTemp, GetCurrentProcess(), &hInputWrite, 0, FALSE, DUPLICATE_CLOSE_SOURCE | DUPLICATE_SAME_ACCESS ); @@ -306,7 +312,7 @@ oslProcessError SAL_CALL osl_executeProcess_WithRedirectedIO( { HANDLE hTemp = NULL; - CreatePipe( &hTemp, &hOutputWrite, NULL, 0 ); + CreatePipe( &hTemp, &hOutputWrite, &sa, 0 ); DuplicateHandle( GetCurrentProcess(), hTemp, GetCurrentProcess(), &hOutputRead, 0, FALSE, DUPLICATE_CLOSE_SOURCE | DUPLICATE_SAME_ACCESS ); @@ -319,7 +325,7 @@ oslProcessError SAL_CALL osl_executeProcess_WithRedirectedIO( { HANDLE hTemp = NULL; - CreatePipe( &hTemp, &hErrorWrite, NULL, 0 ); + CreatePipe( &hTemp, &hErrorWrite, &sa, 0 ); DuplicateHandle( GetCurrentProcess(), hTemp, GetCurrentProcess(), &hErrorRead, 0, FALSE, DUPLICATE_CLOSE_SOURCE | DUPLICATE_SAME_ACCESS ); |