… | |
… | |
27 | #include <openssl/rsa.h> |
27 | #include <openssl/rsa.h> |
28 | |
28 | |
29 | #include "gettext.h" |
29 | #include "gettext.h" |
30 | |
30 | |
31 | #include "slog.h" |
31 | #include "slog.h" |
32 | #include "iom.h" |
32 | #include "ev_cpp.h" |
|
|
33 | #include "callback.h" |
|
|
34 | |
|
|
35 | typedef ev_tstamp tstamp; |
33 | |
36 | |
34 | /* |
37 | /* |
35 | * check for an existing gvpe for this net, and write pid to pidfile |
38 | * check for an existing gvpe for this net, and write pid to pidfile |
36 | */ |
39 | */ |
37 | extern int write_pidfile (void); |
40 | extern int write_pidfile (void); |
… | |
… | |
57 | |
60 | |
58 | extern void id2mac (unsigned int id, void *m); |
61 | extern void id2mac (unsigned int id, void *m); |
59 | |
62 | |
60 | #define mac2id(p) ((p)[0] & 0x01 ? 0 : ((p)[4] << 8) | (p)[5]) |
63 | #define mac2id(p) ((p)[0] & 0x01 ? 0 : ((p)[4] << 8) | (p)[5]) |
61 | |
64 | |
62 | struct sliding_window { |
65 | struct sliding_window |
|
|
66 | { |
63 | u32 v[(WINDOWSIZE + 31) / 32]; |
67 | u32 v[(WINDOWSIZE + 31) / 32]; |
64 | u32 seq; |
68 | u32 seq; |
65 | |
69 | |
66 | void reset (u32 seqno) |
70 | void reset (u32 seqno) |
67 | { |
71 | { |