]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MEDIUM: checks: external checks can't change server status to UP
authorCyril Bonté <cyril.bonte@free.fr>
Wed, 6 Aug 2014 23:55:37 +0000 (01:55 +0200)
committerWilly Tarreau <w@1wt.eu>
Thu, 7 Aug 2014 05:23:51 +0000 (07:23 +0200)
Mark Brooks reported an issue with external healthchecks, where servers are
never marked as UP. This is due to a typo, which flags a successful check as
CHK_RES_FAILED instead of CHK_RES_PASSED.

This bug is specific to the 1.6 branch.

src/checks.c

index 18faa9bbf6609791661878a7d8996535d386e8ad..2c9958acab6264f1b4c472d7101a84d3d531efba 100644 (file)
@@ -93,7 +93,7 @@ static const struct check_status check_statuses[HCHK_STATUS_SIZE] = {
 
        [HCHK_STATUS_PROCERR]   = { CHK_RES_FAILED,   "PROCERR",  "External check error" },
        [HCHK_STATUS_PROCTOUT]  = { CHK_RES_FAILED,   "PROCTOUT", "External check timeout" },
-       [HCHK_STATUS_PROCOK]    = { CHK_RES_FAILED,   "PROCOK",   "External check passed" },
+       [HCHK_STATUS_PROCOK]    = { CHK_RES_PASSED,   "PROCOK",   "External check passed" },
 };
 
 static const struct analyze_status analyze_statuses[HANA_STATUS_SIZE] = {              /* 0: ignore, 1: error, 2: OK */