MCPcopy Create free account
hub / github.com/EmbeddedRPC/erpc / erpc_server_deinit

Function erpc_server_deinit

erpc_c/setup/erpc_server_setup.cpp:105–123  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

103}
104
105void erpc_server_deinit(erpc_server_t server)
106{
107#if ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_STATIC
108 (void)server;
109 erpc_assert(reinterpret_cast<SimpleServer *>(server) == s_server.get());
110 s_crc16.destroy();
111 s_codecFactory.destroy();
112 s_server.destroy();
113#elif ERPC_ALLOCATION_POLICY == ERPC_ALLOCATION_POLICY_DYNAMIC
114 erpc_assert(server != NULL);
115 SimpleServer *simpleServer = reinterpret_cast<SimpleServer *>(server);
116
117 delete simpleServer->getCodecFactory();
118 delete simpleServer->getTransport()->getCrc16();
119 delete simpleServer;
120#else
121#error "Unknown eRPC allocation policy!"
122#endif
123}
124
125void erpc_add_service_to_server(erpc_server_t server, void *service)
126{

Callers 9

mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85
mainFunction · 0.85

Calls 5

destroyMethod · 0.80
getCodecFactoryMethod · 0.80
getTransportMethod · 0.80
getMethod · 0.45
getCrc16Method · 0.45

Tested by 3

mainFunction · 0.68
mainFunction · 0.68
mainFunction · 0.68