]> git.kaiwu.me - haproxy.git/commit
[MEDIUM] secure the calling conditions of ->set_server_status_{up,down}
authorWilly Tarreau <w@1wt.eu>
Fri, 30 Nov 2007 10:11:02 +0000 (11:11 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 30 Nov 2007 10:11:02 +0000 (11:11 +0100)
commit0ebe106ef1337a62b226a954d95225f0432c7963
tree7724cc1e32dd27a3e49fd6ba574e8a7666886392
parent48494c0c5c4d08492522aa00296143c6b6a72943
[MEDIUM] secure the calling conditions of ->set_server_status_{up,down}

It's not always obvious for the callers of set_server_status_{up,down}
whether the new state really is up or down. Some flags as well as the
effective weight have to be considered. Let's ensure that those functions
perform the necessary check themselves so that if the state transition
cannot be performed, at least everything is updated as required.
src/backend.c