Substitution of bind socket address: 192.168.0.10 (my local) -> 0.0.0.0

Questions about Wine on Linux
Locked
LevCor
Newbie
Newbie
Posts: 3
Joined: Thu Aug 13, 2020 5:33 am

Substitution of bind socket address: 192.168.0.10 (my local) -> 0.0.0.0

Post by LevCor »

I have a project on Delphi that uses a UDP server. The problem is that the server that is created and bound with the address 192.168.0.10 in my Delphi code, but in fact in Linux under Wine the address becomes 0.0.0.0 (not 192.168.0.10!). In Windows, everything is proceeding as I write in code - binding occur with 192.168.0.10. When I compiled this fragment of code in Lazarus and build for Linux (native code), the address also became 192.168.0.10. I want exactly this address in my Delphi project, because when server use 0.0.0.0, I have a lot of errors (already used address), and this project is difficult to correct.
Code:

Code: Select all

  UdpSocketHandle1 := IdUdpServer1.Bindings.Add;
  UdpSocketHandle1.IP := '192.168.0.10';
  UdpSocketHandle1.Port := 6201;
  IdUDPServer1.Active := True;
Locked