/* Checks if a string is an alias for another command. If yes, then it replaces the alias name with the correct command name. */
EFI_STATUS ShellConvertAlias(IN OUT CHAR16 **CommandString)
/* Checks if a string is an alias for another command. If yes, then it replaces the alias name with the correct command name. */
EFI_STATUS ShellConvertAlias(IN OUT CHAR16 **CommandString)
{
  CONST CHAR16  *NewString;
  NewString = ShellInfoObject.NewEfiShellProtocol->GetAlias (*CommandString, NULL);
  if (NewString == NULL) {
    return (EFI_SUCCESS);
  }
  FreePool (*CommandString);
  *CommandString = AllocateCopyPool (StrSize (NewString), NewString);
  if (*CommandString == NULL) {
    return (EFI_OUT_OF_RESOURCES);
  }
  return (EFI_SUCCESS);
}