Deallocates a connection structure that was created with smc_connect_alloc.
SMC_RETURN_CODE smc_connect_drop (SMC_CONNECT_ID clientId)
identifies the connection.
Return value |
Indicates |
---|---|
SMC_RET_SUCCESS |
Function succeeded. |
SMC_RET_FAILURE |
Function failed. |
SMC_RET_INVALID_CONNECT |
Connection does not exist. |
This example assumes that:
You have created a connection using smc_connect_alloc and have a clientId.
You have successfully executed smc_close on the connection.
if (smc_connect_drop(clientId) != SMC_RET_SUCCESS) { printf("smc_connect_drop failed\n"); /* do some cleanup */ }
smc_close must be called before smc_connect_drop, if a connection was successfully made.
Mode |
Availability |
---|---|
SMC_SERVER_M_LIVE |
Yes |
SMC_SERVER_M_HISTORICAL |
Yes |
Error |
Indicates |
---|---|
SMC_RET_CONNECT_NOT_CLOSED |
Connection has not been closed |
SMC_RET_INVALID_API_FUNCTION |
Invalid use of obsolete and replacement functions on the same connection |
SMC_RET_INVALID_API_FUNC_SEQUENCE |
Invalid calling sequence of Monitor Client Library functions |
smc_close, smc_connect_alloc