aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-12-13 18:38:26 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-12-13 18:38:26 -0500
commit524e7facc87e746745af9095a3f100dcec1799b6 (patch)
tree3711beec7e1e9aa937e86883e38505beddded382 /src
parentdcd06597a7cc1d4a7829ed75e0a6b1e52fd5c10e (diff)
fix socket errors on linux under .net core
Diffstat (limited to 'src')
-rw-r--r--src/Emby.Server/Program.cs9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/Emby.Server/Program.cs b/src/Emby.Server/Program.cs
index 24e391c73..26141a0ce 100644
--- a/src/Emby.Server/Program.cs
+++ b/src/Emby.Server/Program.cs
@@ -215,9 +215,12 @@ namespace Emby.Server
var initProgress = new Progress<double>();
- // Not crazy about this but it's the only way to suppress ffmpeg crash dialog boxes
- SetErrorMode(ErrorModes.SEM_FAILCRITICALERRORS | ErrorModes.SEM_NOALIGNMENTFAULTEXCEPT |
- ErrorModes.SEM_NOGPFAULTERRORBOX | ErrorModes.SEM_NOOPENFILEERRORBOX);
+ if (environmentInfo.OperatingSystem == MediaBrowser.Model.System.OperatingSystem.Windows)
+ {
+ // Not crazy about this but it's the only way to suppress ffmpeg crash dialog boxes
+ SetErrorMode(ErrorModes.SEM_FAILCRITICALERRORS | ErrorModes.SEM_NOALIGNMENTFAULTEXCEPT |
+ ErrorModes.SEM_NOGPFAULTERRORBOX | ErrorModes.SEM_NOOPENFILEERRORBOX);
+ }
var task = _appHost.Init(initProgress);
Task.WaitAll(task);