|
|
@ -49,8 +49,8 @@ namespace Emby.Server.Implementations.LiveTv.EmbyTV
|
|
|
|
_logger.Info("Copying recording stream to file {0}", targetFile);
|
|
|
|
_logger.Info("Copying recording stream to file {0}", targetFile);
|
|
|
|
|
|
|
|
|
|
|
|
// The media source if infinite so we need to handle stopping ourselves
|
|
|
|
// The media source if infinite so we need to handle stopping ourselves
|
|
|
|
//var durationToken = new CancellationTokenSource(duration);
|
|
|
|
var durationToken = new CancellationTokenSource(duration);
|
|
|
|
//cancellationToken = CancellationTokenSource.CreateLinkedTokenSource(cancellationToken, durationToken.Token).Token;
|
|
|
|
cancellationToken = CancellationTokenSource.CreateLinkedTokenSource(cancellationToken, durationToken.Token).Token;
|
|
|
|
|
|
|
|
|
|
|
|
await directStreamProvider.CopyToAsync(output, cancellationToken).ConfigureAwait(false);
|
|
|
|
await directStreamProvider.CopyToAsync(output, cancellationToken).ConfigureAwait(false);
|
|
|
|
}
|
|
|
|
}
|
|
|
|