From 6baf01ac3b1b3ec23ff042715753b5517e41ffd8 Mon Sep 17 00:00:00 2001 From: Bradasparky <49656562+Bradasparky@users.noreply.github.com> Date: Thu, 15 Jan 2026 19:31:01 -0500 Subject: [PATCH] Fixed KvDeleteKey and KvGetNameSymbol not working from the root node (#2388) --- core/smn_keyvalues.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/smn_keyvalues.cpp b/core/smn_keyvalues.cpp index c6eddc36..985e7805 100644 --- a/core/smn_keyvalues.cpp +++ b/core/smn_keyvalues.cpp @@ -945,7 +945,7 @@ static cell_t smn_KvDeleteKey(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Invalid key value handle %x (error %d)", hndl, herr); } - if (pStk->pCurRoot.size() < 2) + if (pStk->pCurRoot.size() < 1) { return 0; } @@ -1038,7 +1038,7 @@ static cell_t smn_GetNameSymbol(IPluginContext *pContext, const cell_t *params) return pContext->ThrowNativeError("Invalid key value handle %x (error %d)", hndl, herr); } - if (pStk->pCurRoot.size() < 2) + if (pStk->pCurRoot.size() < 1) { return 0; }