mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-15 23:58:57 +00:00
Replace ISocket and UdpSocket, fix DLNA and SSDP binding and discovery
This commit is contained in:
@@ -1025,7 +1025,7 @@ namespace Emby.Server.Implementations
|
||||
return PublishedServerUrl.Trim('/');
|
||||
}
|
||||
|
||||
string smart = NetManager.GetBindInterface(hostname, out var port);
|
||||
string smart = NetManager.GetBindAddress(hostname, out var port);
|
||||
return GetLocalApiUrl(smart.Trim('/'), null, port);
|
||||
}
|
||||
|
||||
@@ -1033,7 +1033,7 @@ namespace Emby.Server.Implementations
|
||||
public string GetApiUrlForLocalAccess(IPAddress ipAddress = null, bool allowHttps = true)
|
||||
{
|
||||
// With an empty source, the port will be null
|
||||
var smart = NetManager.GetBindAddress(ipAddress, out _);
|
||||
var smart = NetManager.GetBindAddress(ipAddress, out _, true);
|
||||
var scheme = !allowHttps ? Uri.UriSchemeHttp : null;
|
||||
int? port = !allowHttps ? HttpPort : null;
|
||||
return GetLocalApiUrl(smart, scheme, port);
|
||||
|
||||
Reference in New Issue
Block a user