From b52890d8426c4a5018932fd6f551e369eb7e14c1 Mon Sep 17 00:00:00 2001 From: Max Wash Date: Sun, 19 Apr 2026 20:00:16 +0100 Subject: [PATCH] kernel: object: add missing parentheses to OBJECT_CAST --- include/kernel/object.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/kernel/object.h b/include/kernel/object.h index 74b2bd0..3444f3d 100644 --- a/include/kernel/object.h +++ b/include/kernel/object.h @@ -65,7 +65,7 @@ extern "C" { #define OBJECT_PATH_MAX 256 #define OBJECT_CAST(to_type, to_type_member, p) \ - ((to_type *)((uintptr_t)p) - offsetof(to_type, to_type_member)) + ((to_type *)(((uintptr_t)p) - offsetof(to_type, to_type_member))) #define OBJECT_C_CAST(c_type, c_type_member, obj_type, objp) \ OBJECT_IS_TYPE(objp, obj_type) \ ? OBJECT_CAST(c_type, c_type_member, (objp)) : NULL