mirror of
https://github.com/zeek/zeek.git
synced 2025-10-08 17:48:21 +00:00
Only allow a single trace file (-r) or interface (-i) option on the command-line
This commit is contained in:
parent
2b2121be60
commit
f16f0360ff
17 changed files with 93 additions and 141 deletions
|
@ -1902,11 +1902,11 @@ double current_time(bool real)
|
|||
|
||||
double t = double(tv.tv_sec) + double(tv.tv_usec) / 1e6;
|
||||
|
||||
if ( ! pseudo_realtime || real || ! iosource_mgr || iosource_mgr->GetPktSrcs().empty() )
|
||||
if ( ! pseudo_realtime || real || ! iosource_mgr || ! iosource_mgr->GetPktSrc() )
|
||||
return t;
|
||||
|
||||
// This obviously only works for a single source ...
|
||||
iosource::PktSrc* src = iosource_mgr->GetPktSrcs().front();
|
||||
iosource::PktSrc* src = iosource_mgr->GetPktSrc();
|
||||
|
||||
if ( net_is_processing_suspended() )
|
||||
return src->CurrentPacketTimestamp();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue