X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Flibmeshlink.h;h=4c7c4a95a5d81afd4957e92b64a0d62b400b29d6;hb=1564f52f7643c554ec49a3e014bc9b9a8745c856;hp=4b3139157ca9460650e1fd59eb4920e9f6fc5596;hpb=e59147ed89bd287212dba28c13873e7ab3613a57;p=meshlink diff --git a/src/libmeshlink.h b/src/libmeshlink.h index 4b313915..4c7c4a95 100644 --- a/src/libmeshlink.h +++ b/src/libmeshlink.h @@ -19,13 +19,18 @@ #include "system.h" #include "node.h" -#include "names.h" //#include "tincctl.h" #include "xalloc.h" +#include "logger.h" +#include "route.h" extern char *hosts_dir; +extern FILE *fopenmask(const char *filename, const char *mode, mode_t perms); extern int check_port(char *name); + +bool tinc_main_thread(void * in); + /* OLD: tinc_configuration_t provides all information required to setup "/etc/tinc" I think tinc_setup() should basically do what cmd_init() from src/tincctl.c does, except it doesn't have to generate a tinc-up script. */ @@ -35,6 +40,11 @@ bool tinc_start(const char* path); bool tinc_stop(); +typedef struct tincpackethdr { + u_int8_t destination[16]; + u_int8_t source[16]; +} __attribute__ ((__packed__)) tincpackethdr; + // can be called from any thread bool tinc_send_packet(node_t *receiver, const char* buf, unsigned int len);