diff --git a/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c b/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c index 9cc9ed7d36..7703e52fe3 100644 --- a/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c +++ b/ArmPkg/Filesystem/SemihostFs/Arm/SemihostFs.c @@ -1158,7 +1158,7 @@ FileSetInfo ( Buffer = SystemInfo->VolumeLabel; - if (StrSize (Buffer) > 0) { + if (StrLen (Buffer) > 0) { VolumeLabel = AllocateCopyPool (StrSize (Buffer), Buffer); if (VolumeLabel != NULL) { FreePool (mSemihostFsLabel);