override buffer size only for windows

pull/702/head
Luke Pulverenti 9 years ago
parent 8b93bd6eab
commit 2f40910c90

@ -275,10 +275,14 @@ namespace MediaBrowser.Server.Implementations.IO
{ {
var newWatcher = new FileSystemWatcher(path, "*") var newWatcher = new FileSystemWatcher(path, "*")
{ {
IncludeSubdirectories = true, IncludeSubdirectories = true
InternalBufferSize = 32767
}; };
if (Environment.OSVersion.Platform == PlatformID.Win32NT)
{
newWatcher.InternalBufferSize = 32767;
}
newWatcher.NotifyFilter = NotifyFilters.CreationTime | newWatcher.NotifyFilter = NotifyFilters.CreationTime |
NotifyFilters.DirectoryName | NotifyFilters.DirectoryName |
NotifyFilters.FileName | NotifyFilters.FileName |

Loading…
Cancel
Save