diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2000-07-09 21:02:44 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2000-07-09 21:02:44 +0000 |
commit | d501c6adee491009ce6ebde3581b6743937794f1 (patch) | |
tree | 446af91c6cf1ac50427d7750d36bef56780afae7 /winsup/cygwin/spawn.cc | |
parent | 5fc3f2d40a7b47d16860f026d2f9e86af93cb9f5 (diff) | |
download | newlib-d501c6adee491009ce6ebde3581b6743937794f1.zip newlib-d501c6adee491009ce6ebde3581b6743937794f1.tar.gz newlib-d501c6adee491009ce6ebde3581b6743937794f1.tar.bz2 |
* spawn.cc (spawn_guts): Close handle `hToken' only if it's not
copied from myself->token.
* syscalls.cc (seteuid): Replace CopySid by memcpy which is foolproof
here.
Diffstat (limited to 'winsup/cygwin/spawn.cc')
-rw-r--r-- | winsup/cygwin/spawn.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/spawn.cc b/winsup/cygwin/spawn.cc index 734d2d2..f6da863 100644 --- a/winsup/cygwin/spawn.cc +++ b/winsup/cygwin/spawn.cc @@ -640,7 +640,7 @@ skip_arg_parsing: ResumeThread (pi.hThread); ForceCloseHandle (pi.hThread); - if (hToken) + if (hToken && hToken != myself->token) CloseHandle (hToken); DWORD res; |