[Nagiosplug-devel] RE: nagiosplug- check_snmp

Karl DeBisschop karl at debisschop.net
Fri Nov 15 10:06:02 CET 2002


On Fri, 2002-11-15 at 12:39, Subhendu Ghosh wrote:

> > In other words, the code comments are dead on to mark it experimental.
> > We should also make sure it is so marked if it appears in the docs.
> > 
> > > Also the flags should get set in the check_num() routine when iresult is 
> > > modified - but currently don't - so the flags are superflous at the 
> > > moment.
> 
> (WARN|CRIT)_PRESENT flags are never set anywhere - they are just checked -
> hence my comment about the superflous if/else statement above.  check_num
> should set these flags in addition to setting the result.
> 

That's incorrect:

line 449 of 1.18

> 
> > 
> > I'm not following you here. Can you explain this to me again?
> > 
> > > My ref to line 326 was in v1.8 - current CVS line 358-360 - should be 
> > > concatanated with an "else" clause instead of being separate if 
> > > statements.
> > 
> 
> the basic login checking the output in the while loop
> 
> if (WARN|CRIT comparion flags set)

no.

if (PRESENT)

else? if (INTEGER comparison)

 <then as below>

> 
> else if ( STRING comparision flag set)
> 
> else if (REGEX comparison flag set)
> 
> else ( no comparision flags set)
> 
> 
> currently the trailing else clause is not present (but the contents of the 
> clause are present as a separate statement over-riding the logic)

but maybe your logic is better, even if it is not what is currently
there.

> 
> I'll put the changes into CVS.

-- 
Karl DeBisschop <karl at debisschop.net>





More information about the Devel mailing list