Renaming the Logger to Reporter.

Also changing output to not include timestamps when we haven't started
processing packets yet.
This commit is contained in:
Robin Sommer 2011-07-01 09:22:33 -07:00
parent 93894eed9b
commit 66e2c3b623
123 changed files with 722 additions and 713 deletions

View file

@ -10,7 +10,7 @@
#include "NetVar.h"
#include "Scope.h"
#include "File.h"
#include "Logger.h"
#include "Reporter.h"
// FIXME: Things that are not fully implemented/working yet:
//
@ -201,7 +201,7 @@ bool RuleMatcher::ReadFiles(const name_list& files)
rules_in = search_for_file( files[i], "sig", 0, false);
if ( ! rules_in )
{
bro_logger->Error("Can't open signature file", files[i]);
reporter->Error("Can't open signature file", files[i]);
return false;
}
@ -401,7 +401,7 @@ static inline uint32 getval(const u_char* data, int size)
return ntohl(*(uint32*) data);
default:
bro_logger->InternalError("illegal HdrTest size");
reporter->InternalError("illegal HdrTest size");
}
// Should not be reached.
@ -514,7 +514,7 @@ RuleEndpointState* RuleMatcher::InitEndpoint(Analyzer* analyzer,
default:
data = 0;
bro_logger->InternalError("unknown protocol");
reporter->InternalError("unknown protocol");
}
// ### data can be nil here if it's an
@ -543,7 +543,7 @@ RuleEndpointState* RuleMatcher::InitEndpoint(Analyzer* analyzer,
DO_MATCH_OR(*h->vals, getval(data + h->offset, h->size), >=);
default:
bro_logger->InternalError("unknown comparision type");
reporter->InternalError("unknown comparision type");
}
no_match:
@ -570,7 +570,7 @@ void RuleMatcher::Match(RuleEndpointState* state, Rule::PatternType type,
{
if ( ! state )
{
bro_logger->Warning("RuleEndpointState not initialized yet.");
reporter->Warning("RuleEndpointState not initialized yet.");
return;
}