aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/Session/SessionManager.cs
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2015-03-29 14:16:40 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2015-03-29 14:16:40 -0400
commitdd8dd1938a990d9c4c9bac384665dc9d82c4bc35 (patch)
treee82fff87bac89c10ccc8af334d44eb52b9aa5b85 /MediaBrowser.Server.Implementations/Session/SessionManager.cs
parenta79962b7ebfe59d837970581ac1b5f184b0aa42d (diff)
update live stream generation
Diffstat (limited to 'MediaBrowser.Server.Implementations/Session/SessionManager.cs')
-rw-r--r--MediaBrowser.Server.Implementations/Session/SessionManager.cs24
1 files changed, 24 insertions, 0 deletions
diff --git a/MediaBrowser.Server.Implementations/Session/SessionManager.cs b/MediaBrowser.Server.Implementations/Session/SessionManager.cs
index 16fc42063..cc5aef54a 100644
--- a/MediaBrowser.Server.Implementations/Session/SessionManager.cs
+++ b/MediaBrowser.Server.Implementations/Session/SessionManager.cs
@@ -679,6 +679,18 @@ namespace MediaBrowser.Server.Implementations.Session
}
}
+ if (!string.IsNullOrWhiteSpace(info.LiveStreamId))
+ {
+ try
+ {
+ await _mediaSourceManager.PingLiveStream(info.LiveStreamId, CancellationToken.None).ConfigureAwait(false);
+ }
+ catch (Exception ex)
+ {
+ _logger.ErrorException("Error closing live stream", ex);
+ }
+ }
+
EventHelper.FireEventIfNotNull(PlaybackProgress, this, new PlaybackProgressEventArgs
{
Item = libraryItem,
@@ -769,6 +781,18 @@ namespace MediaBrowser.Server.Implementations.Session
}
}
+ if (!string.IsNullOrWhiteSpace(info.LiveStreamId))
+ {
+ try
+ {
+ await _mediaSourceManager.CloseLiveStream(info.LiveStreamId, CancellationToken.None).ConfigureAwait(false);
+ }
+ catch (Exception ex)
+ {
+ _logger.ErrorException("Error closing live stream", ex);
+ }
+ }
+
EventHelper.QueueEventIfNotNull(PlaybackStopped, this, new PlaybackStopEventArgs
{
Item = libraryItem,