mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-01 13:28:27 +01:00
fix mapping multiple tuner channels to same epg channel
This commit is contained in:
@@ -324,7 +324,7 @@ namespace MediaBrowser.ServerApplication
|
||||
/// <param name="options">The options.</param>
|
||||
private static void RunApplication(ServerApplicationPaths appPaths, ILogManager logManager, bool runService, StartupOptions options)
|
||||
{
|
||||
var fileSystem = new ManagedFileSystem(logManager.GetLogger("FileSystem"), true, true, true, appPaths.TempDirectory);
|
||||
var fileSystem = new ManagedFileSystem(logManager.GetLogger("FileSystem"), true, true, false, appPaths.TempDirectory);
|
||||
fileSystem.AddShortcutHandler(new LnkShortcutHandler());
|
||||
fileSystem.AddShortcutHandler(new MbLinkShortcutHandler(fileSystem));
|
||||
|
||||
|
||||
@@ -27,38 +27,6 @@ namespace MediaBrowser.ServerApplication
|
||||
get { return MainStartup.IsRunningAsService; }
|
||||
}
|
||||
|
||||
protected override FFMpegInstallInfo GetFfmpegInstallInfo()
|
||||
{
|
||||
var info = new FFMpegInstallInfo();
|
||||
|
||||
info.FFMpegFilename = "ffmpeg.exe";
|
||||
info.FFProbeFilename = "ffprobe.exe";
|
||||
info.Version = "20160410";
|
||||
info.ArchiveType = "7z";
|
||||
info.DownloadUrls = GetDownloadUrls();
|
||||
|
||||
return info;
|
||||
}
|
||||
|
||||
private string[] GetDownloadUrls()
|
||||
{
|
||||
switch (EnvironmentInfo.SystemArchitecture)
|
||||
{
|
||||
case Architecture.X64:
|
||||
return new[]
|
||||
{
|
||||
"https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/windows/ffmpeg-20160410-win64.7z"
|
||||
};
|
||||
case Architecture.X86:
|
||||
return new[]
|
||||
{
|
||||
"https://github.com/MediaBrowser/Emby.Resources/raw/master/ffmpeg/windows/ffmpeg-20160410-win32.7z"
|
||||
};
|
||||
}
|
||||
|
||||
return new string[] { };
|
||||
}
|
||||
|
||||
protected override void RestartInternal()
|
||||
{
|
||||
MainStartup.Restart();
|
||||
@@ -94,7 +62,7 @@ namespace MediaBrowser.ServerApplication
|
||||
|
||||
protected override void ConfigureAutoRunInternal(bool autorun)
|
||||
{
|
||||
var startupPath = System.Environment.GetFolderPath(System.Environment.SpecialFolder.Startup);
|
||||
var startupPath = Environment.GetFolderPath(System.Environment.SpecialFolder.Startup);
|
||||
|
||||
if (autorun && !MainStartup.IsRunningAsService)
|
||||
{
|
||||
@@ -121,14 +89,6 @@ namespace MediaBrowser.ServerApplication
|
||||
}
|
||||
}
|
||||
|
||||
protected override bool SupportsDualModeSockets
|
||||
{
|
||||
get
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
protected override void EnableLoopbackInternal(string appName)
|
||||
{
|
||||
LoopUtil.Run(appName);
|
||||
@@ -150,14 +110,6 @@ namespace MediaBrowser.ServerApplication
|
||||
}
|
||||
}
|
||||
|
||||
public override bool SupportsAutoRunAtStartup
|
||||
{
|
||||
get
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
public override bool CanSelfUpdate
|
||||
{
|
||||
get
|
||||
@@ -165,61 +117,5 @@ namespace MediaBrowser.ServerApplication
|
||||
return MainStartup.CanSelfUpdate;
|
||||
}
|
||||
}
|
||||
|
||||
public bool PortsRequireAuthorization(string applicationPath)
|
||||
{
|
||||
var appNameSrch = Path.GetFileName(applicationPath);
|
||||
|
||||
var startInfo = new ProcessStartInfo
|
||||
{
|
||||
FileName = "netsh",
|
||||
|
||||
Arguments = "advfirewall firewall show rule \"" + appNameSrch + "\"",
|
||||
|
||||
CreateNoWindow = true,
|
||||
UseShellExecute = false,
|
||||
WindowStyle = ProcessWindowStyle.Hidden,
|
||||
ErrorDialog = false,
|
||||
RedirectStandardOutput = true
|
||||
};
|
||||
|
||||
using (var process = Process.Start(startInfo))
|
||||
{
|
||||
process.Start();
|
||||
|
||||
try
|
||||
{
|
||||
var data = process.StandardOutput.ReadToEnd() ?? string.Empty;
|
||||
|
||||
if (data.IndexOf("Block", StringComparison.OrdinalIgnoreCase) != -1)
|
||||
{
|
||||
Logger.Info("Found potential windows firewall rule blocking Emby Server: " + data);
|
||||
}
|
||||
|
||||
//var parts = data.Split('\n');
|
||||
|
||||
//return parts.Length > 4;
|
||||
//return Confirm();
|
||||
return false;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Logger.ErrorException("Error querying windows firewall", ex);
|
||||
|
||||
// Hate having to do this
|
||||
try
|
||||
{
|
||||
process.Kill();
|
||||
}
|
||||
catch (Exception ex1)
|
||||
{
|
||||
Logger.ErrorException("Error killing process", ex1);
|
||||
}
|
||||
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user