/* This function changes the file size info from the FileHandle's EFI_FILE_INFO data. */
EFI_STATUS EFIAPI FileHandleSetSize(IN EFI_FILE_HANDLE FileHandle, IN UINT64 Size)
/* This function changes the file size info from the FileHandle's EFI_FILE_INFO data. */
EFI_STATUS EFIAPI FileHandleSetSize(IN EFI_FILE_HANDLE FileHandle, IN UINT64 Size)
{
  EFI_FILE_INFO  *FileInfo;
  EFI_STATUS     Status;
  if (FileHandle == NULL) {
    return (EFI_INVALID_PARAMETER);
  }
  FileInfo = FileHandleGetInfo (FileHandle);
  if (FileInfo == NULL) {
    return (EFI_DEVICE_ERROR);
  }
  FileInfo->FileSize = Size;
  Status = FileHandleSetInfo (FileHandle, FileInfo);
  FreePool (FileInfo);
  return (Status);
}