mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2024-12-15 07:54:33 +00:00
BUILD: stream-int: avoid a build warning in dev mode in si_state_bit()
The BUG_ON() test emits a warning about an always-true comparison regarding <state> which cannot be lower than zero. Let's get rid of it.
This commit is contained in:
parent
1ec9bb5b62
commit
ad660e3f84
@ -143,7 +143,7 @@ static inline void si_set_state(struct stream_interface *si, int state)
|
||||
/* returns a bit for a stream-int state, to match against SI_SB_* */
|
||||
static inline enum si_state_bit si_state_bit(enum si_state state)
|
||||
{
|
||||
BUG_ON(state < SI_ST_INI || state > SI_ST_CLO);
|
||||
BUG_ON(state > SI_ST_CLO);
|
||||
return 1U << state;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user