Open topic with navigation
WTSupported in traditional Synergy on Windows
WNSupported in Synergy .NET on Windows
USupported on UNIX
VSupported on OpenVMS
status = %SS_GETNAMEINFO(in_addr, h_name[, flag])
If successful, returns SS_SUCCESS (0). If unsuccessful, returns SS_ENULL (2). See the Socket Errors table for additional information about this error. (n)
Specifies an IPv4 address. (i4)
Returned with the host name. (a)
(optional) Specifies the behavior: (i4)
Returns h_name in numeric form (but note that it will still be an alpha).
Returns only the host name portion of the fully‑qualified domain name.
Returns SS_ENULL as status if the host name cannot be determined.
%SS_GETNAMEINFO retrieves a host name using the host address in_addr as a search parameter.
The form of h_name depends on the system implementation (and on whether you pass NI_NOFQDN). For example, it may return a simple host name such as socrates or a fully‑qualified domain name such as socrates.synergex.com. If you pass the NI_NOFQDN flag, it will return only the simple host name, even if the domain name is available.
If h_name cannot be determined, the numeric form of in_addr is returned, unless you have specified NI_NAMEREQD, in which case SS_ENULL will be returned.
If SS_ENULL is returned, the system error code can be returned by immediately calling %SYSERR.