Refactors hash entry state setters to ease override

This commit is contained in:
Simone Mainardi 2019-08-05 12:12:16 +02:00
parent 0e3b359f0f
commit f110602192
8 changed files with 40 additions and 10 deletions

View file

@ -26,7 +26,7 @@
GenericHashEntry::GenericHashEntry(NetworkInterface *_iface) {
hash_next = NULL, iface = _iface, first_seen = last_seen = 0, num_uses = 0;
hash_entry_state = hash_entry_state_active;
set_hash_entry_state_active();
if(iface && iface->getTimeLastPktRcvd() > 0)
first_seen = last_seen = iface->getTimeLastPktRcvd();