benilla-re systems structs docs

ParseAddressPiece

function · os · primitive

Address
0x43f3d0 · 110 bytes, up to 0x43f43d
Signature
void __fastcall (const char *text, uint32_t port, void *out)
Meaning
Writes a sockaddr_in: inet_addr of the text before a colon, the number after it as the port
Confidence
verified, proof two
Finding
net/dial#address-piece
Test
net::dial_digit_piece, net::dial_resolve_thread

Finding: Address piece in net: dial

A piece that begins with a digit goes to 0x43f3d0 with the request's port. With a : in it, the text before the first : goes to inet_addr, and SStrToInt of the text after it is the port. Without one, the whole piece goes to inet_addr and the port is the request's. The entry holds the address inet_addr returned, whatever it is: a text it rejects is stored and added like any address. The piece is never looked up by name, so a host name that begins with a digit, such as 3com.example, is stored with whatever inet_addr returns for it.

The derivation is in the doc.

Callers 1

Callees 3

Calls and jumps by a bare address, from tables/calls.tsv.