.TH SXHUB_CREATE 3 "20 July 2015" "SXMP" "SXMP Library Manual" .SH NAME sxhub_create \- Allocate and initialize connections system .br sxhub_init \- Initialize connections system .br sxhub_destroy \- Destroy connections system .br sxhub_free \- Free all stuff allocated for connections system .SH SYNOPSIS .B #include .sp sxhub_t *sxhub_create(void); int sxhub_init(sxhub_t *ssys); int sxhub_destroy(sxhub_t *ssys); int sxhub_free(sxhub_t *ssys); .br .sp .SH DESCRIPTION .B sxhub_create will create a separate connections set used for handling creation and initialization of the connection links. .B sxhub_init will do the same, but it will take an already preallocated pointer. .br .B sxhub_destroy will deallocate all related to the connections set, include pointer .BI ssys , but .B sxhub_free will not free this pointer consider it will be deallocated by user. .br .SH RETURN VALUE Upon successful completion, the function .B sxhub_create will return a valid pointer to the connections set. .B sxhub_init will return .B 0 .br Otherwise NULL will be returned and errno will be set, or error will be returned, in case of .B sxhub_init use. .SH ERRORS .B sxhub_init will return, .B sxhub_create will set .B errno to: .br .B ENOMEM Not enough memory to allocate all required stuff. .br .B EINVAL Returned if invalid pointer given. .br .SH BUGS Not known yet. .SH EXAMPLE None. .SH APPLICATION USAGE None. .SH RATIONALE Connection link destroy function might be used carefully, the logic of there functions is a send a special link layer message that will close the connection link on the master side. The reason to care about is a delivery of all messages, channels and other stuff, because when this functions called all pending messages are drops. .SH SEE ALSO .BI sxhub_setsslserts(3) , .BI sxmp_init(3) .SH COPYRIGHT This is a proprietary software. See COPYING for further details. .br (c) Askele Group 2013-2015 .SH AUTHOR Alexander Vdolainen (vdo@askele.com)