mirror of
https://github.com/rustdesk/rustdesk.git
synced 2024-11-30 17:19:03 +08:00
fix nt_terminate_process missing CloseHandle (#8294)
Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
parent
be16f1be44
commit
ffac670f95
@ -2503,8 +2503,10 @@ fn nt_terminate_process(process_id: DWORD) -> ResultType<()> {
|
||||
if !h_token.is_null() {
|
||||
if f_nt_terminate_process(h_token, 1) == 0 {
|
||||
log::info!("terminate process {} success", process_id);
|
||||
CloseHandle(h_token);
|
||||
return Ok(());
|
||||
} else {
|
||||
CloseHandle(h_token);
|
||||
bail!("NtTerminateProcess {} failed", process_id);
|
||||
}
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user