/* Function to determine if a given filename exists. */
EFI_STATUS EFIAPI ShellFileExists(IN CONST CHAR16 *Name)
/* Function to determine if a given filename exists. */
EFI_STATUS EFIAPI ShellFileExists(IN CONST CHAR16 *Name)
{
  EFI_STATUS           Status;
  EFI_SHELL_FILE_INFO  *List;
  ASSERT (Name != NULL);
  List   = NULL;
  Status = ShellOpenFileMetaArg ((CHAR16 *)Name, EFI_FILE_MODE_READ, &List);
  if (EFI_ERROR (Status)) {
    return (Status);
  }
  ShellCloseFileMetaArg (&List);
  return (EFI_SUCCESS);
}