aboutsummaryrefslogtreecommitdiff
path: root/Jellyfin.Api/Helpers/ProgressiveFileCopier.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Jellyfin.Api/Helpers/ProgressiveFileCopier.cs')
-rw-r--r--Jellyfin.Api/Helpers/ProgressiveFileCopier.cs4
1 files changed, 1 insertions, 3 deletions
diff --git a/Jellyfin.Api/Helpers/ProgressiveFileCopier.cs b/Jellyfin.Api/Helpers/ProgressiveFileCopier.cs
index 963e17724..81970b041 100644
--- a/Jellyfin.Api/Helpers/ProgressiveFileCopier.cs
+++ b/Jellyfin.Api/Helpers/ProgressiveFileCopier.cs
@@ -1,7 +1,6 @@
using System;
using System.Buffers;
using System.IO;
-using System.Runtime.InteropServices;
using System.Threading;
using System.Threading.Tasks;
using Jellyfin.Api.Models.PlaybackDtos;
@@ -85,8 +84,7 @@ namespace Jellyfin.Api.Helpers
var fileOptions = FileOptions.SequentialScan;
var allowAsyncFileRead = false;
- // use non-async filestream along with read due to https://github.com/dotnet/corefx/issues/6039
- if (!RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
+ if (AsyncFile.UseAsyncIO)
{
fileOptions |= FileOptions.Asynchronous;
allowAsyncFileRead = true;