while this is really just a string, on the interface side it must be treated\r
as an opaque var which is passed as "var" when it needs to be modified}\r
\r
- tbiniplist=tipstring;\r
+ tbiniplist=tbufferstring;\r
\r
function biniplist_new:tbiniplist;\r
procedure biniplist_add(var l:tbiniplist;ip:tbinip);\r
procedure biniplist_setcount(var l:tbiniplist;newlen:integer);\r
procedure biniplist_free(var l:tbiniplist);\r
procedure biniplist_addlist(var l:tbiniplist;const l2:tbiniplist);\r
-function biniplist_tostr(const l:tbiniplist):tipstring;\r
+function biniplist_tostr(const l:tbiniplist):thostname;\r
function isbiniplist(const l:tbiniplist):boolean;\r
\r
function htons(w:word):word;\r
function htonl(i:uint32):uint32;\r
\r
-function ipstrtobin(const s:tipstring;var binip:tbinip):boolean;\r
-function ipstrtobinf(const s:tipstring):tbinip;\r
-function ipbintostr(const binip:tbinip):tipstring;\r
+function ipstrtobin(const s:thostname;var binip:tbinip):boolean;\r
+function ipstrtobinf(const s:thostname):tbinip;\r
+function ipbintostr(const binip:tbinip):thostname;\r
{$ifdef ipv6}\r
-function ip6bintostr(const bin:tin6_addr):tipstring;\r
-function ip6strtobin(const s:tipstring;var bin:tin6_addr):boolean;\r
+function ip6bintostr(const bin:tin6_addr):thostname;\r
+function ip6strtobin(const s:thostname;var bin:tin6_addr):boolean;\r
{$endif}\r
\r
function comparebinip(const ip1,ip2:tbinip):boolean;\r
procedure addipsoffamily(var l:tbiniplist;const l2:tbiniplist;family:integer);\r
\r
{deprecated}\r
-function longip(s:tipstring):longint;\r
+function longip(s:thostname):longint;\r
\r
function needconverttov4(const ip:tbinip):boolean;\r
procedure converttov4(var ip:tbinip);\r
\r
{internal}\r
{converts dotted v4 IP to longint. returns host endian order}\r
-function longip(s:tipstring):longint;\r
+function longip(s:thostname):longint;\r
var\r
l:longint;\r
a,b:integer;\r
ipstrtobin(s,result);\r
end;\r
\r
-function ipstrtobin(const s:tipstring;var binip:tbinip):boolean;\r
+function ipstrtobin(const s:thostname;var binip:tbinip):boolean;\r
begin\r
binip.family := 0;\r
result := false;\r
end;\r
end;\r
\r
-function ipbintostr(const binip:tbinip):tipstring;\r
+function ipbintostr(const binip:tbinip):thostname;\r
var\r
a:integer;\r
begin\r
{fpc has hostaddrtostr6 and strtohostaddr6 but the later isnt implemented yet}\r
\r
\r
-function ip6bintostr(const bin:tin6_addr):tipstring;\r
+function ip6bintostr(const bin:tin6_addr):thostname;\r
{base16 with lowercase output}\r
function makehex(w:word):ansistring;\r
begin\r
end;\r
end;\r
\r
-function ip6strtobin(const s:tipstring;var bin:tin6_addr):boolean;\r
+function ip6strtobin(const s:thostname;var bin:tin6_addr):boolean;\r
var\r
a,b:integer;\r
fields:array[0..7] of ansistring;\r
l := l + copy(l2,biniplist_prefixlen+1,maxlongint);\r
end;\r
\r
-function biniplist_tostr(const l:tbiniplist):tipstring;\r
+function biniplist_tostr(const l:tbiniplist):thostname;\r
var\r
a:integer;\r
begin\r