On 30/01/07 04:00 AM, Jan Wagner wrote: > Hi Thomas, > > thanks for your help. > > # LANG=C ./check_tcp -H jabber.org -p 5223 --send="<stream:stream > to=\'jabber.org\' xmlns=\'jabber:client\' > xmlns:stream=\'http://etherx.jabber.org/streams\'>\n" --expect="<?xml > version=\'1.0\'?><stream:stream > xmlns:stream=\'http://etherx.jabber.org/streams\'" > --quit="</stream:stream>\n" --ssl -j > TCP WARNING - Unexpected response from host/socket on port 5223| > time=0.703722s;0.000000;0.000000;0.000000;10.000000 > > # LANG=C ./check_tcp -H jabber.org -p 5223 --send="<stream:stream > to=\'jabber.org\' xmlns=\'jabber:client\' > xmlns:stream=\'http://etherx.jabber.org/streams\'>\n" --expect="<?xml > version=\'1.0\'?><stream:stream > xmlns:stream=\'http://etherx.jabber.org/streams\'" > --quit="</stream:stream>\n" --ssl --jail > ./check_TCP: option `--jail' requires an argument > > Hmm .. is there any trouble with "--jail" there?
Aww, that's definitely a bug. Why '-j' works but not '--jail' is a mistery for me though :/ Use the attached patch to fix your problem. Ton, do you have any idea why -j worked but not --jail? Should we use all long options in "make test" scripts? Thomas
Index: plugins/check_tcp.c =================================================================== RCS file: /cvsroot/nagiosplug/nagiosplug/plugins/check_tcp.c,v retrieving revision 1.83 diff -u -r1.83 check_tcp.c --- plugins/check_tcp.c 30 Jan 2007 05:01:00 -0000 1.83 +++ plugins/check_tcp.c 30 Jan 2007 14:21:27 -0000 @@ -408,7 +408,7 @@ {"expect", required_argument, 0, 'e'}, {"maxbytes", required_argument, 0, 'm'}, {"quit", required_argument, 0, 'q'}, - {"jail", required_argument, 0, 'j'}, + {"jail", no_argument, 0, 'j'}, {"delay", required_argument, 0, 'd'}, {"refuse", required_argument, 0, 'r'}, {"mismatch", required_argument, 0, 'M'},