mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-09-06 03:26:07 +02:00
fix udp server messages
This commit is contained in:
parent
3a4befff6b
commit
88d5e34210
2 changed files with 2 additions and 2 deletions
|
@ -24,7 +24,7 @@ namespace MediaBrowser.Common.Implementations.NetworkManagement
|
|||
{
|
||||
var host = Dns.GetHostEntry(Dns.GetHostName());
|
||||
|
||||
var ip = host.AddressList.FirstOrDefault(i => i.AddressFamily == AddressFamily.InterNetwork);
|
||||
var ip = host.AddressList.LastOrDefault(i => i.AddressFamily == AddressFamily.InterNetwork);
|
||||
|
||||
if (ip == null)
|
||||
{
|
||||
|
|
|
@ -296,7 +296,7 @@ namespace MediaBrowser.Server.Implementations.ServerManager
|
|||
_logger.Info("Received UDP server request from " + e.RemoteEndPoint);
|
||||
|
||||
// Send a response back with our ip address and port
|
||||
var response = String.Format("MediaBrowser{0}|{1}:{2}", context, _networkManager.GetLocalIpAddress(), _kernel.UdpServerPortNumber);
|
||||
var response = String.Format("MediaBrowser{0}|{1}:{2}", context, _networkManager.GetLocalIpAddress(), ConfigurationManager.Configuration.HttpServerPortNumber);
|
||||
|
||||
await UdpServer.SendAsync(Encoding.UTF8.GetBytes(response), e.RemoteEndPoint);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue