Update constants, data

This commit is contained in:
Théophile Bastian 2016-11-20 00:15:09 +01:00
parent c53125384d
commit e5857f842d
2 changed files with 13 additions and 1 deletions

10
data.h
View file

@ -7,8 +7,18 @@
#pragma once #pragma once
#include <cstdint> #include <cstdint>
#include <arpa/inet.h>
typedef uint8_t u8; typedef uint8_t u8;
typedef uint16_t u16; typedef uint16_t u16;
typedef uint32_t u32; typedef uint32_t u32;
typedef uint64_t u64;
typedef struct sockaddr_in6 SockAddr;
struct Neighbour {
Neighbour(u64 id, const SockAddr& addr) : id(id), addr(addr) {}
u64 id;
SockAddr addr;
};

View file

@ -29,5 +29,7 @@ const int TIMEOUT_UNIDIR = 100*1000; // ms
const int TIMEOUT_SYM_RECV = 150*1000; // ms const int TIMEOUT_SYM_RECV = 150*1000; // ms
const int TIMEOUT_SYM_IHU = 300*1000; // ms const int TIMEOUT_SYM_IHU = 300*1000; // ms
}; const u16 DEFAULT_PORT = 1192;
}