From 81613cd5f125bb196753c497c5440daa69775c8d Mon Sep 17 00:00:00 2001 From: Amlal EL Mahrouss Date: Sat, 29 Jun 2024 23:53:51 +0200 Subject: New err_ kernel API (with err_bug_check) (FIXES) Signed-off-by: Amlal EL Mahrouss --- Kernel/Sources/Network/IPCEP.cxx | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'Kernel') diff --git a/Kernel/Sources/Network/IPCEP.cxx b/Kernel/Sources/Network/IPCEP.cxx index 9e198385..930969fb 100644 --- a/Kernel/Sources/Network/IPCEP.cxx +++ b/Kernel/Sources/Network/IPCEP.cxx @@ -56,16 +56,19 @@ _Fail: return false; } -/// @brief Sanitize packet function -/// @retval true packet is correct. -/// @retval false packet is incorrect and process has crashed. -Bool ipc_sanitize_packet(IPCEPMessageHeader* pckt) +namespace NewOS { - if (!__ipc_sanitize_packet(pckt)) + /// @brief Sanitize packet function + /// @retval true packet is correct. + /// @retval false packet is incorrect and process has crashed. + Bool ipc_sanitize_packet(IPCEPMessageHeader* pckt) { - ProcessScheduler::The().Leak().TheCurrent().Leak().Crash(); - return false; - } + if (!__ipc_sanitize_packet(pckt)) + { + ProcessScheduler::The().Leak().TheCurrent().Leak().Crash(); + return false; + } - return true; + return true; + } } -- cgit v1.2.3