function IpStrToU(sIp:AnsiString):DWORD;
begin
Result:=inet_addr(pAnsiChar(sIp))
end;
function IpUToStr(U:Dword):AnsiString;
var
inaddr: TInAddr;
//sin:sockaddr_in;
begin
//sin.sin_addr.S_addr:=U;
inaddr.S_addr:=U;
Result:=StrPas(inet_ntoa(inaddr))
end;