X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Fmeshlink_internal.h;h=b3ac72c40a2833f74abd78f68cb292b4a54f2e20;hb=fb3ae8985db2f41c498b4fdaf2ca1566dbc84954;hp=517dc1e01cb8dbee31824f040f7c0a6140015f9e;hpb=01eaeb3c9fa60ae9c6e5b866acd9baef79622d99;p=meshlink diff --git a/src/meshlink_internal.h b/src/meshlink_internal.h index 517dc1e0..b3ac72c4 100644 --- a/src/meshlink_internal.h +++ b/src/meshlink_internal.h @@ -54,18 +54,13 @@ typedef enum proxytype_t { PROXY_EXEC, } proxytype_t; -typedef struct outpacketqueue { - meshlink_node_t *destination; - const void *data; - unsigned int len; -} outpacketqueue_t; - /// A handle for an instance of MeshLink. struct meshlink_handle { char *name; + void *priv; + char *appname; dev_class_t devclass; - void *priv; char *confbase; @@ -117,6 +112,8 @@ struct meshlink_handle { bool localdiscovery; sockaddr_t localdiscovery_address; + bool default_blacklist; + hash_t *node_udp_cache; struct connection_t *everyone; struct ecdsa *invitation_key; @@ -152,9 +149,12 @@ struct meshlink_node { /// A channel. struct meshlink_channel { - struct utcp_connection *c; struct node_t *node; + void *priv; + + struct utcp_connection *c; meshlink_channel_receive_cb_t receive_cb; + meshlink_channel_poll_cb_t poll_cb; }; /// Header for data packets routed between nodes @@ -164,6 +164,7 @@ typedef struct meshlink_packethdr { } __attribute__ ((__packed__)) meshlink_packethdr_t; extern void meshlink_send_from_queue(event_loop_t* el,meshlink_handle_t *mesh); +extern void update_node_status(meshlink_handle_t *mesh, struct node_t *n); extern meshlink_log_level_t global_log_level; extern meshlink_log_cb_t global_log_cb;