The Free Software Media System - Server Backend & API
Fix UnauthorizedAccessException in GetDrives
Bond_0090f5289669195
diff --git a/Emby.Server.Implementations/IO/ManagedFileSystem.cs b/Emby.Server.Implementations/IO/ManagedFileSystem.csindex eeee288425..3aefb841e5 100644--- a/Emby.Server.Implementations/IO/ManagedFileSystem.cs+++ b/Emby.Server.Implementations/IO/ManagedFileSystem.cs@@ -580,7 +580,11 @@ namespace Emby.Server.Implementations.IO{// check for ready state to avoid waiting for drives to timeout// some drives on linux have no actual size or are used for other purposes- return DriveInfo.GetDrives().Where(d => d.IsReady && d.TotalSize != 0 && d.DriveType != DriveType.Ram)+ return DriveInfo.GetDrives()+ .Where(+ d => (d.DriveType == DriveType.Fixed || d.DriveType == DriveType.Network || d.DriveType == DriveType.Removable)+ && d.IsReady+ && d.TotalSize != 0).Select(d => new FileSystemMetadata{Name = d.Name,