mirror of
https://github.com/zeek/zeek.git
synced 2025-10-05 08:08:19 +00:00
Remove not-useful code in iosource::Manager::OpenPktSrc
It's generally expected for a PktSrc to not be Open yet right after instantiation, but rather from InitSource() called during the registration process. Besides that, the logic in question would potentially replace an error message that is useful/detailed with one that is not.
This commit is contained in:
parent
02476453bc
commit
4f011a65f4
1 changed files with 0 additions and 4 deletions
|
@ -371,10 +371,6 @@ PktSrc* Manager::OpenPktSrc(const std::string& path, bool is_live)
|
|||
PktSrc* ps = (*component->Factory())(npath, is_live);
|
||||
assert(ps);
|
||||
|
||||
if ( ! ps->IsOpen() && ps->IsError() )
|
||||
// Set an error message if it didn't open successfully.
|
||||
ps->Error("could not open");
|
||||
|
||||
DBG_LOG(DBG_PKTIO, "Created packet source of type %s for %s", component->Name().c_str(), npath.c_str());
|
||||
|
||||
Register(ps);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue