Skip to content
Start free evaluation

pdcomm_tcp_state

Function

Reads the endpoint identity, generation, HSMS state, and close status.

PdcommStatus pdcomm_tcp_state(PdcommTcpEndpoint *endpoint, PdcommTcpState *state)

Declared in: #include <pdcomm_tcp.h>

This call works while an event is staged.

Parameters

NameDescription
endpointLive endpoint.
stateCaller storage. Set state->struct_size to sizeof(PdcommTcpState) or larger before the call; on success the known fields are written and struct_size is set to the size written. Trailing bytes of a larger structure are not touched.

Returns

#PDCOMM_OK on success; #PDCOMM_INVALID_ARGUMENT when endpoint or state is NULL or state->struct_size is too small (nothing is written); #PDCOMM_POISONED.