From 39667de662b00c32b14b7724a01c3ee0f494d2d2 Mon Sep 17 00:00:00 2001 From: Bananymous Date: Sat, 14 Sep 2024 21:17:03 +0300 Subject: [PATCH] Kernel: Fix sizeof check for sys_tc{set,get}attr --- kernel/kernel/Process.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/kernel/Process.cpp b/kernel/kernel/Process.cpp index cdb40be4bb..a4170ae279 100644 --- a/kernel/kernel/Process.cpp +++ b/kernel/kernel/Process.cpp @@ -362,7 +362,7 @@ namespace Kernel { LockGuard _(m_process_lock); - TRY(validate_pointer_access(termios, sizeof(termios), true)); + TRY(validate_pointer_access(termios, sizeof(struct termios), true)); auto inode = TRY(m_open_file_descriptors.inode_of(fildes)); if (!inode->is_tty()) @@ -381,7 +381,7 @@ namespace Kernel LockGuard _(m_process_lock); - TRY(validate_pointer_access(termios, sizeof(termios), false)); + TRY(validate_pointer_access(termios, sizeof(struct termios), false)); auto inode = TRY(m_open_file_descriptors.inode_of(fildes)); if (!inode->is_tty())