Move zeek::net namespace to zeek::run_state namespace.

This also moves all of the code from Net.{h,cc} to RunState.{h,cc} and marks Net.h as deprecated
This commit is contained in:
Tim Wojtulewicz 2020-08-19 17:41:24 -07:00
parent d608e7c9a5
commit 0ac3fafe13
64 changed files with 477 additions and 467 deletions

View file

@ -9,7 +9,7 @@
#include "Manager.h"
#include "Component.h"
#include "IOSource.h"
#include "Net.h"
#include "RunState.h"
#include "PktSrc.h"
#include "PktDumper.h"
#include "plugin/Manager.h"
@ -115,7 +115,7 @@ void Manager::FindReadySources(std::vector<IOSource*>* ready)
// If there aren't any sources and exit_only_after_terminate is false, just
// return an empty set of sources. We want the main loop to end.
if ( Size() == 0 && ( ! zeek::BifConst::exit_only_after_terminate || zeek::net::terminating ) )
if ( Size() == 0 && ( ! zeek::BifConst::exit_only_after_terminate || zeek::run_state::terminating ) )
return;
double timeout = -1;
@ -166,7 +166,7 @@ void Manager::FindReadySources(std::vector<IOSource*>* ready)
}
else
{
if ( ! zeek::net::pseudo_realtime )
if ( ! zeek::run_state::pseudo_realtime )
// A pcap file is always ready to process unless it's suspended
ready->push_back(pkt_src);
}
@ -315,7 +315,7 @@ void Manager::Register(PktSrc* src)
// little bit for those sources.
if ( src->IsLive() )
poll_interval = 10;
else if ( zeek::net::pseudo_realtime )
else if ( zeek::run_state::pseudo_realtime )
poll_interval = 1;
Register(src, false);