mirror of
https://github.com/netchx/netch.git
synced 2026-03-14 17:43:18 +08:00
Fix OnlyInstance Send Command Client bind address
This commit is contained in:
@@ -62,7 +62,7 @@ namespace Netch.Utils
|
||||
{
|
||||
try
|
||||
{
|
||||
using var udpClient = new UdpClient(Global.Settings.UDPSocketPort);
|
||||
using var udpClient = new UdpClient(new IPEndPoint(IPAddress.Loopback, Global.Settings.UDPSocketPort));
|
||||
udpClient.Connect(IPAddress.Loopback, Global.Settings.UDPSocketPort);
|
||||
var sendBytes = Encoding.ASCII.GetBytes(command.ToString());
|
||||
await udpClient.SendAsync(sendBytes, sendBytes.Length);
|
||||
|
||||
Reference in New Issue
Block a user