The Great Embooleanating

A large number of functions had return values and/or arguments changed
to use ``bool`` types instead of ``int``.
This commit is contained in:
Tim Wojtulewicz 2020-03-11 10:41:46 -07:00 committed by Robin Sommer
parent 3c470ffe13
commit fd5e15b116
145 changed files with 1288 additions and 1331 deletions

View file

@ -230,7 +230,7 @@ bool Manager::CreateStream(EnumVal* id, RecordVal* sval)
{
RecordType* rtype = sval->Type()->AsRecordType();
if ( ! same_type(rtype, BifType::Record::Log::Stream, 0) )
if ( ! same_type(rtype, BifType::Record::Log::Stream, false) )
{
reporter->Error("sval argument not of right type");
return false;
@ -288,7 +288,7 @@ bool Manager::CreateStream(EnumVal* id, RecordVal* sval)
if ( ! same_type((*args)[0], columns) )
{
reporter->Error("stream event's argument type does not match column record type");
return val_mgr->GetBool(0);
return val_mgr->GetFalse();
}
}
@ -533,7 +533,7 @@ bool Manager::AddFilter(EnumVal* id, RecordVal* fval)
{
RecordType* rtype = fval->Type()->AsRecordType();
if ( ! same_type(rtype, BifType::Record::Log::Filter, 0) )
if ( ! same_type(rtype, BifType::Record::Log::Filter, false) )
{
reporter->Error("filter argument not of right type");
return false;
@ -1401,7 +1401,7 @@ public:
~RotationTimer();
void Dispatch(double t, int is_expire);
void Dispatch(double t, bool is_expire) override;
protected:
Manager::WriterInfo* winfo;
@ -1414,7 +1414,7 @@ RotationTimer::~RotationTimer()
winfo->rotation_timer = 0;
}
void RotationTimer::Dispatch(double t, int is_expire)
void RotationTimer::Dispatch(double t, bool is_expire)
{
winfo->rotation_timer = 0;