Xymon Mailing List Archive search

Bug in bbcombotest 4.3.0-beta2

list Japheth Cleaver
Mon, 31 Jan 2011 13:28:45 -0800
Message-Id: <user-880d716bb336@xymon.invalid>

I noticed the logic below seems to still be present in 4.3.0-RC1 (line 211 in xymond/combostatus.c). Does anyone know if it's still occurring or if this patch is still needed?

-jc
-----Original Message-----
From: Francesco Duranti [mailto:user-7104dcecbfef@xymon.invalid]
Sent: Friday, July 24, 2009 10:31 AM
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] Bug in bbcombotest 4.3.0-beta2

Hi all,
I don't know if anyone use it or is interested but there's a bug in 4.3.0-beta2 (and 4.4.0 too)
related to the bbcombotest.

The bug is at line 216 in the if just after the sendmessage...

This is the code interested... the problem is that in 4.3.0 variable board is not passed to
sendmessage anymore (as in 4.2.3) so the if for the error is always true and the test are not checked.

                hobbitdresult = sendmessage("hobbitdboard fields=hostname,testname,color", NULL,
BBTALK_TIMEOUT, sres);
                if ((hobbitdresult != BB_OK) || (board == NULL)) {
                        board = "";
                        *errptr += sprintf(*errptr, "Could not access hobbitd board, error %d\n",
hobbitdresult);
                        return COL_CLEAR;
                }

Changing the "if" to "if (hobbitdresult != BB_OK) {" should solve the problem.