From a461a1b5a568087ea4991cb3af2300dd6f8ef90e Mon Sep 17 00:00:00 2001 From: Amlal El Mahrouss Date: Fri, 19 Sep 2025 10:22:54 +0200 Subject: feat: kernel && libDDK: `DDK` and `kernel` improvements. what: - Hardened `AsciiUtils` and `libDDK` Signed-off-by: Amlal El Mahrouss --- dev/libDDK/src/ddk_dev.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'dev/libDDK/src/ddk_dev.c') diff --git a/dev/libDDK/src/ddk_dev.c b/dev/libDDK/src/ddk_dev.c index 32ec2442..d20684aa 100644 --- a/dev/libDDK/src/ddk_dev.c +++ b/dev/libDDK/src/ddk_dev.c @@ -11,7 +11,7 @@ /// @brief Open a new binary device from path. DDK_EXTERN DDK_DEVICE_PTR open(const char* devicePath) { - if (!devicePath) return nil; + if (nil == devicePath) return nil; return ke_call_dispatch("dk_open_dev", 1, (void*) devicePath, kstrlen(devicePath)); } @@ -19,7 +19,7 @@ DDK_EXTERN DDK_DEVICE_PTR open(const char* devicePath) { /// @brief Close any device. /// @param device valid device. DDK_EXTERN BOOL close(DDK_DEVICE_PTR device) { - if (!device) return NO; + if (nil == device) return NO; ke_call_dispatch("dk_close_dev", 1, device, sizeof(DDK_DEVICE)); return YES; -- cgit v1.2.3