pdcomm_opcua_server_local_address
Function
Returns the socket address the server listens on.
int32_t pdcomm_opcua_server_local_address(pdcomm_opcua_handle server, pdcomm_opcua_handle *out)Useful after binding port 0. The result is an owned buffer with UTF-8 text such as 127.0.0.1:50123, without a terminator.
Parameters
| Name | Description |
|---|---|
server | Server handle. |
out | Receives the buffer handle. |
Returns
#PDCOMM_OPCUA_OK, #PDCOMM_OPCUA_CLOSED, #PDCOMM_OPCUA_RUNTIME_ERROR, #PDCOMM_OPCUA_LIMIT, #PDCOMM_OPCUA_BUSY, #PDCOMM_OPCUA_INVALID_HANDLE or #PDCOMM_OPCUA_POISONED.