aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/EntryPoints/SystemEvents.cs
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2017-09-20 13:22:39 -0400
committerGitHub <noreply@github.com>2017-09-20 13:22:39 -0400
commiteb2a1330045d802bfe0366df7105c220a36f111f (patch)
tree2c1638c424ee9c0837c5de6d6e08a2398da69cdb /Emby.Server.Implementations/EntryPoints/SystemEvents.cs
parentec426d5c92875639ceac64477ce10fab3e639335 (diff)
parenta015e1208885bc6a8788db683c4fe47e93dc26b7 (diff)
Merge pull request #2897 from MediaBrowser/beta
Beta
Diffstat (limited to 'Emby.Server.Implementations/EntryPoints/SystemEvents.cs')
-rw-r--r--Emby.Server.Implementations/EntryPoints/SystemEvents.cs10
1 files changed, 1 insertions, 9 deletions
diff --git a/Emby.Server.Implementations/EntryPoints/SystemEvents.cs b/Emby.Server.Implementations/EntryPoints/SystemEvents.cs
index 4ab6d32f3..08f3edb3d 100644
--- a/Emby.Server.Implementations/EntryPoints/SystemEvents.cs
+++ b/Emby.Server.Implementations/EntryPoints/SystemEvents.cs
@@ -23,18 +23,9 @@ namespace Emby.Server.Implementations.EntryPoints
public void Run()
{
- _systemEvents.SessionLogoff += _systemEvents_SessionLogoff;
_systemEvents.SystemShutdown += _systemEvents_SystemShutdown;
}
- private void _systemEvents_SessionLogoff(object sender, EventArgs e)
- {
- if (!_appHost.IsRunningAsService)
- {
- _appHost.Shutdown();
- }
- }
-
private void _systemEvents_SystemShutdown(object sender, EventArgs e)
{
_appHost.Shutdown();
@@ -43,6 +34,7 @@ namespace Emby.Server.Implementations.EntryPoints
public void Dispose()
{
_systemEvents.SystemShutdown -= _systemEvents_SystemShutdown;
+ GC.SuppressFinalize(this);
}
}
}