// UEFI Shell spec section 3.7)\r
if ((PathSize != 0) &&\r
(PathForReturn != NULL) &&\r
- (PathForReturn[PathSize - 1] != L'\\') &&\r
+ (PathForReturn[PathSize / sizeof (CHAR16) - 1] != L'\\') &&\r
(AlignedNode->PathName[0] != L'\\')) {\r
PathForReturn = StrnCatGrow (&PathForReturn, &PathSize, L"\\", 1);\r
}\r