New shutdown function.

This commit is contained in:
Nicolás A. Ortega
2017-07-02 17:13:59 +02:00
parent a393cb8b4e
commit 0db8eb82e9
4 changed files with 19 additions and 2 deletions

View File

@ -30,3 +30,8 @@
* else 0 is returned.
*/
int NeoComm_init(unsigned int max_nodes);
/**
* @brief Disconnect all currently active connections and shutdown all modules.
*/
void NeoComm_shutdown();

View File

@ -27,6 +27,9 @@ struct address {
unsigned short port; ///< Port of address.
};
/**
* @brief Structure used for NeoComm nodes.
*/
struct node {
/// The address of the node.
struct address address;
@ -50,7 +53,10 @@ struct node {
*/
int NeoComm_init_nodes(unsigned int max_nodes);
void NeoComm_deinit_nodes();
/**
* @brief Deinitialize all the nodes.
*/
void NeoComm_shutdown_nodes();
/**
* @brief Enlarge the list.