MCPcopy Create free account
hub / github.com/acl-dev/acl / server_alloc

Function server_alloc

lib_fiber/cpp/src/fiber_server.cpp:732–748  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

730}
731
732static FIBER_SERVER *server_alloc(int socket_count, int fdtype)
733{
734 FIBER_SERVER *server = (FIBER_SERVER *)
735 acl_mycalloc(1, sizeof(FIBER_SERVER));
736
737 server->socket_count = socket_count;
738 server->fdtype = fdtype;
739 server->in = acl_mbox_create();
740 server->out = acl_mbox_create();
741
742 server->sstreams = (ACL_VSTREAM **)
743 acl_mycalloc(socket_count, sizeof(ACL_VSTREAM *));
744 server->accepters = (ACL_FIBER **)
745 acl_mycalloc(socket_count, sizeof(ACL_FIBER *));
746
747 return server;
748}
749
750static void server_free(FIBER_SERVER *server)
751{

Callers 1

servers_allocFunction · 0.70

Calls 1

acl_mbox_createFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…