For node with index 0, the result of this function contains leading L'/' character. But for other nodes no such characters (separators) returned. Make processing of all fields consistent.
After this patch the debug output for specified URI is the following: @Redfish.Settings found:/redfish/v1/Systems/system/Bios/Settings GetNumberOfRedpathNodes:6 GetRedpathNodeByIndex[0]:redfish/v1/Systems/system/Bios/Settings GetRedpathNodeByIndex[1]:v1/Systems/system/Bios/Settings GetRedpathNodeByIndex[2]:Systems/system/Bios/Settings GetRedpathNodeByIndex[3]:system/Bios/Settings GetRedpathNodeByIndex[4]:Bios/Settings GetRedpathNodeByIndex[5]:Settings Cc: Abner Chang <abner.ch...@amd.com> Cc: Igor Kulchytskyy <ig...@ami.com> Cc: Nickle Wang <nick...@nvidia.com> Signed-off-by: Mike Maslenkin <mike.maslen...@gmail.com> --- .../Library/RedfishFeatureUtilityLib/RedfishFeatureUtilityLib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/RedfishClientPkg/Library/RedfishFeatureUtilityLib/RedfishFeatureUtilityLib.c b/RedfishClientPkg/Library/RedfishFeatureUtilityLib/RedfishFeatureUtilityLib.c index b0a3b20a40bd..c55dc2ee6d05 100644 --- a/RedfishClientPkg/Library/RedfishFeatureUtilityLib/RedfishFeatureUtilityLib.c +++ b/RedfishClientPkg/Library/RedfishFeatureUtilityLib/RedfishFeatureUtilityLib.c @@ -1304,7 +1304,7 @@ GetRedpathNodeByIndex ( NumberNodes = 0; StringLen = StrLen (NodeString); StringIndex = 1; // ConfigLang always starts with '/'. - NodeStart = NodeString; + NodeStart = NodeString + StringIndex; if (EndOfNodePtr != NULL) { *EndOfNodePtr = NULL; } -- 2.32.0 (Apple Git-132) -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#117068): https://edk2.groups.io/g/devel/message/117068 Mute This Topic: https://groups.io/mt/105101993/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-