BUG/MINOR: peers: fix data_type bit computation more than 32 data_types
authorEmeric Brun <ebrun@haproxy.com>
Thu, 1 Jul 2021 16:54:05 +0000 (18:54 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Tue, 6 Jul 2021 16:14:20 +0000 (18:14 +0200)
commitcecd1d3bd27bcd79db16a50e98e798dee4333d34
tree3ebea5cc0796601b213d1874e3c5ab7a5beb68e8
parent31f5ed68d3c19a2c86a2181084f80f175831298d
BUG/MINOR: peers: fix data_type bit computation more than 32 data_types

This patch fixes the computation of the bit of the current data_type
in some part of code of peer protocol where the computation is limited
to 32bits whereas the bitfield of data_types can support 64bits.

Without this patch it could result in bugs when we will define more
than 32 data_types.

Backport is useless because there is currently less than 32 data_types

(cherry picked from commit 08b0f6780c45099b8d03bfd9e398d3f51519e667)
Signed-off-by: Willy Tarreau <w@1wt.eu>
(cherry picked from commit 45f12b06b491b433fdb951ba851284e46901a917)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
src/peers.c