From efc22dcc12930de6c55aa111eb669ae04d68e88e Mon Sep 17 00:00:00 2001 From: al3w0f205 Date: Wed, 28 Oct 2026 20:17:10 -0500 Subject: [PATCH] test(ulobjmgr): cover NID aliases _sceUlobjmgrRegisterObject_nid_postfix and _sceUlobjmgrUnregisterObject_nid_postfix --- core/libs/tests/GuestUlobjmgr.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/core/libs/tests/GuestUlobjmgr.cpp b/core/libs/tests/GuestUlobjmgr.cpp index 3f6795a979..8a04790859 100644 --- a/core/libs/tests/GuestUlobjmgr.cpp +++ b/core/libs/tests/GuestUlobjmgr.cpp @@ -25,4 +25,18 @@ int main() { Require(_sceUlobjmgrUnregisterObject(0x3fff) == 0); Require(_sceUlobjmgrUnregisterObject(0x4000) == einval); Require(_sceUlobjmgrUnregisterObject(0xffffffffu) == einval); + + std::uint32_t nidId = 0xffffffffu; + Require(_sceUlobjmgrRegisterObject_nid_postfix(0, 1, &nidId) == einval); + Require(nidId == 0xffffffffu); + Require(_sceUlobjmgrRegisterObject_nid_postfix(0x1000, 0, &nidId) == einval); + Require(nidId == 0xffffffffu); + Require(_sceUlobjmgrRegisterObject_nid_postfix(0x1000, 1, nullptr) == einval); + Require(_sceUlobjmgrRegisterObject_nid_postfix(0x1000, -1, &nidId) == 0); + Require(nidId == 0); + + Require(_sceUlobjmgrUnregisterObject_nid_postfix(nidId) == 0); + Require(_sceUlobjmgrUnregisterObject_nid_postfix(0x3fff) == 0); + Require(_sceUlobjmgrUnregisterObject_nid_postfix(0x4000) == einval); + Require(_sceUlobjmgrUnregisterObject_nid_postfix(0xffffffffu) == einval); }