]> git.tdb.fi Git - netvis.git/blobdiff - source/netvis.h
Avoid unsigned int overflow if total number of hosts exceeds the maximum
[netvis.git] / source / netvis.h
index eb8c0a8e9d66fab276be8e6cd93687302a11db78..a205d0564af72b89e340173b212614cc54a5c404 100644 (file)
@@ -20,6 +20,7 @@ Distributed unter the GPL
 #include <msp/gl/font.h>
 #include <msp/time/timestamp.h>
 
+class History;
 class Host;
 class Packet;
 class Port;
@@ -43,6 +44,7 @@ private:
        std::map<unsigned, Host *> disabled_hosts;
        std::list<Packet *> packets;
        std::map<unsigned, Port *> ports;
+       History *history;
 
        Msp::Time::TimeStamp tick_t;
        Msp::Time::TimeStamp fps_t;
@@ -61,7 +63,8 @@ private:
        void render();
        Host &get_host(unsigned);
        Msp::GL::Color generate_color(bool) const;
-       const Port &get_port(unsigned);
+       Port &get_port(unsigned);
+       void create_history_texture();
 
        static void capture_handler(unsigned char *, const pcap_pkthdr *, const unsigned char *);