MINOR: checks: use check->state instead of srv->state & SRV_CHECKED
Having the check state partially stored in the server doesn't help.
Some functions such as srv_getinter() rely on the server being checked
to decide what check frequency to use, instead of relying on the check
being configured. So let's get rid of SRV_CHECKED and SRV_AGENT_CHECKED
and only use the check's states instead.
diff --git a/include/types/server.h b/include/types/server.h
index 7775369..54ab813 100644
--- a/include/types/server.h
+++ b/include/types/server.h
@@ -48,7 +48,7 @@
#define SRV_BACKUP 0x0002 /* this server is a backup server */
#define SRV_MAPPORTS 0x0004 /* this server uses mapped ports */
/* unused: 0x0008 */
-#define SRV_CHECKED 0x0010 /* this server needs to be checked */
+/* unused: 0x0010 */
#define SRV_GOINGDOWN 0x0020 /* this server says that it's going down (404) */
#define SRV_WARMINGUP 0x0040 /* this server is warming up after a failure */
#define SRV_MAINTAIN 0x0080 /* this server is in maintenance mode */
@@ -56,9 +56,6 @@
/* unused: 0x0200, 0x0400 */
#define SRV_SEND_PROXY 0x0800 /* this server talks the PROXY protocol */
#define SRV_NON_STICK 0x1000 /* never add connections allocated to this server to a stick table */
-#define SRV_AGENT_CHECKED 0x2000 /* this server needs to be checked using an agent check.
- * This is run independently of the main check whose
- * presence is indicated by the SRV_CHECKED flag */
/* function which act on servers need to return various errors */
#define SRV_STATUS_OK 0 /* everything is OK. */