4. Client Side
Prev | Chapter 9. The COMSTACK Module | Next

## 4. Client Side

        int cs_connect(COMSTACK handle, void *address);

Initiate a connection with the target at `address` (more on addresses below). The function will return 0 on success, and 1 if the operation does not complete immediately (this will only happen on a nonblocking endpoint). In this case, use `cs_rcvconnect` to complete the operation, when `select(2)` or `poll(2)` reports input pending on the association.

        int cs_rcvconnect(COMSTACK handle);

Complete a connect operation initiated by `cs_connect()`. It will return 0 on success; 1 if the operation has not yet completed (in this case, call the function again later); -1 if an error has occurred.

Prev | Up | Next
3. Common Functions | Home | 5. Server Side