* sec_auth.cc (lsaauth): Close unused handle.

(lsaprivkeyauth): Ditto.
This commit is contained in:
Corinna Vinschen 2009-06-25 08:22:09 +00:00
parent 9ed8b4d807
commit 21a49eaeeb
2 changed files with 13 additions and 2 deletions

View File

@ -1,3 +1,8 @@
2009-06-25 Corinna Vinschen <corinna@vinschen.de>
* sec_auth.cc (lsaauth): Close unused handle.
(lsaprivkeyauth): Ditto.
2009-06-23 Corinna Vinschen <corinna@vinschen.de>
* sec_auth.cc (get_server_groups): Ignore errors from

View File

@ -1087,7 +1087,10 @@ lsaauth (cygsid &usersid, user_groups &new_groups, struct passwd *pw)
{
debug_printf ("Linked Token: %p", linked.LinkedToken);
if (linked.LinkedToken)
user_token = linked.LinkedToken;
{
CloseHandle (user_token);
user_token = linked.LinkedToken;
}
}
}
@ -1178,7 +1181,10 @@ lsaprivkeyauth (struct passwd *pw)
{
debug_printf ("Linked Token: %p", linked.LinkedToken);
if (linked.LinkedToken)
token = linked.LinkedToken;
{
CloseHandle (token);
token = linked.LinkedToken;
}
}
}
if (!SetHandleInformation (token, HANDLE_FLAG_INHERIT,