fix is_physical_console_session (#7266)

Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
21pages 2024-02-26 13:34:26 +08:00 committed by GitHub
parent 1bc11a207a
commit 2920e33d71
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -746,7 +746,7 @@ pub fn get_current_process_session_id() -> Option<u32> {
pub fn is_physical_console_session() -> Option<bool> {
if let Some(sid) = get_current_process_session_id() {
let physical_console_session_id = unsafe { get_current_session(TRUE) };
let physical_console_session_id = unsafe { get_current_session(FALSE) };
if physical_console_session_id == u32::MAX {
return None;
}