mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-20 17:14:42 +01:00
added out of network bitrate limit
This commit is contained in:
@@ -101,12 +101,6 @@ namespace MediaBrowser.Common.Implementations
|
||||
/// <value>The failed assemblies.</value>
|
||||
public List<string> FailedAssemblies { get; protected set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets all types within all running assemblies
|
||||
/// </summary>
|
||||
/// <value>All types.</value>
|
||||
public Type[] AllTypes { get; protected set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets all concrete types.
|
||||
/// </summary>
|
||||
@@ -438,9 +432,10 @@ namespace MediaBrowser.Common.Implementations
|
||||
Logger.Info("Loading {0}", assembly.FullName);
|
||||
}
|
||||
|
||||
AllTypes = assemblies.SelectMany(GetTypes).ToArray();
|
||||
|
||||
AllConcreteTypes = AllTypes.Where(t => t.IsClass && !t.IsAbstract && !t.IsInterface && !t.IsGenericType).ToArray();
|
||||
AllConcreteTypes = assemblies
|
||||
.SelectMany(GetTypes)
|
||||
.Where(t => t.IsClass && !t.IsAbstract && !t.IsInterface && !t.IsGenericType)
|
||||
.ToArray();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
@@ -172,11 +172,11 @@ namespace MediaBrowser.Common.Implementations.Networking
|
||||
Uri uri;
|
||||
if (Uri.TryCreate(endpoint, UriKind.RelativeOrAbsolute, out uri))
|
||||
{
|
||||
var host = uri.DnsSafeHost;
|
||||
Logger.Debug("Resolving host {0}", host);
|
||||
|
||||
try
|
||||
{
|
||||
var host = uri.DnsSafeHost;
|
||||
Logger.Debug("Resolving host {0}", host);
|
||||
|
||||
address = GetIpAddresses(host).FirstOrDefault();
|
||||
|
||||
if (address != null)
|
||||
@@ -186,9 +186,13 @@ namespace MediaBrowser.Common.Implementations.Networking
|
||||
return IsInLocalNetworkInternal(address.ToString(), false);
|
||||
}
|
||||
}
|
||||
catch (InvalidOperationException)
|
||||
{
|
||||
// Can happen with reverse proxy or IIS url rewriting
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Logger.ErrorException("Error resovling hostname {0}", ex, host);
|
||||
Logger.ErrorException("Error resovling hostname", ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user