]> git.meshlink.io Git - meshlink/blobdiff - src/node.h
Count the number of correctly received UDP packets.
[meshlink] / src / node.h
index 3327fca29c2921027f805cf665e5f6921fdabbeb..662ad68311b7ad0e53b8ac138fd9c038a4339f35 100644 (file)
@@ -25,6 +25,7 @@
 #include "cipher.h"
 #include "connection.h"
 #include "digest.h"
+#include "event.h"
 #include "subnet.h"
 
 typedef struct node_status_t {
@@ -76,6 +77,7 @@ typedef struct node_t {
 
        uint32_t sent_seqno;                    /* Sequence number last sent to this node */
        uint32_t received_seqno;                /* Sequence number last received from this node */
+       uint32_t received;                      /* Total valid packets received from this node */
        uint32_t farfuture;                     /* Packets in a row that have arrived from the far future */
        unsigned char* late;                    /* Bitfield marking late packets */
 
@@ -83,7 +85,7 @@ typedef struct node_t {
        length_t minmtu;                        /* Probed minimum MTU */
        length_t maxmtu;                        /* Probed maximum MTU */
        int mtuprobes;                          /* Number of probes */
-       struct event mtuevent;                  /* Probe event */
+       timeout_t mtutimeout;                   /* Probe event */
 
        uint64_t in_packets;
        uint64_t in_bytes;