[Nagiosplug-devel] [Nagiosplug-checkins] nagiosplug/plugins check_by_ssh.c, 1.41, 1.42

Andreas Ericsson ae at op5.se
Tue Apr 17 17:15:11 CEST 2007


Holger Weiss wrote:
> * Andreas Ericsson <ae at op5.se> [2007-04-17 15:24]:
>> Holger Weiss wrote:
>>> Update of /cvsroot/nagiosplug/nagiosplug/plugins
>>> In directory sc8-pr-cvs16:/tmp/cvs-serv13836/plugins
>>>
>>> Modified Files:
>>> 	check_by_ssh.c
>>> Log Message:
>>> Up to revision 1.35, the "-S" option skipped the specified number of
>>> lines written to stderr.  With revision 1.36 and newer, "-S" skipped the
>>> specified number of lines written to stdout.  Now, "-S" skips the
>>> specified number of lines written to stderr; and if the number specified
>>> via "-S" minus the number of lines written to stderr is larger than 0,
>>> the difference is used as the number of lines written to stdout to skip.
>>> Also, the "--help" output was fixed.  (Hector - 1675286) 
>> So.. If --skip=10 is used, and there's 7 lines of output on stderr, the first
>> 3 lines of stdout are skipped?
> 
> Yes.
> 
>> Why not just keep "--skiplines" as-is
> 
> You mean keep it as it was up to r1.35 ("--skip-stderr") or between
> r1.36 and r1.41 ("--skip-stdout")?
> 

I'm not sure. Whichever was used in the most stable releases, I guess :P

Mucking with how options work is not a good idea in a product so widely
used as the nagiosplugins. Literally speaking, they're run tens of
millions of times every day over the world.

>> and introduce --skip-stderr and --skip-stdout, which would solve the
>> same problem in a more intuitive way, not break backwards-compatibility
>> *and* provide a finer granularity.
> 
> Well, the problem I tried to fix was that we *did* break backwards
> compatibility with releases <= 1.4.2 and users complained about that.
> My idea was to make things somewhat compatible with both the old and the
> new behaviour.  However, I agree that the result really seems too
> clumsy, especially as it doesn't provide real backwards compatibility
> anyway.  Actually, I thought about reverting that in favour of the
> options you suggested myself.  Convinced, will do.
> 

Thanks. That should keep everyone happy (well, theoretically anyways).

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231




More information about the Devel mailing list