mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
gcc: keep using unsigned type
This commit is contained in:
parent
534760398c
commit
de837c15a5
@ -1317,7 +1317,7 @@ int dm_bit_get_next(dm_bitset_t bs, int last_bit);
|
|||||||
int dm_bit_get_last(dm_bitset_t bs);
|
int dm_bit_get_last(dm_bitset_t bs);
|
||||||
int dm_bit_get_prev(dm_bitset_t bs, int last_bit);
|
int dm_bit_get_prev(dm_bitset_t bs, int last_bit);
|
||||||
|
|
||||||
#define DM_BITS_PER_INT (sizeof(int) * CHAR_BIT)
|
#define DM_BITS_PER_INT ((unsigned)sizeof(int) * CHAR_BIT)
|
||||||
|
|
||||||
#define dm_bit(bs, i) \
|
#define dm_bit(bs, i) \
|
||||||
((bs)[((i) / DM_BITS_PER_INT) + 1] & (0x1 << ((i) & (DM_BITS_PER_INT - 1))))
|
((bs)[((i) / DM_BITS_PER_INT) + 1] & (0x1 << ((i) & (DM_BITS_PER_INT - 1))))
|
||||||
|
@ -2242,7 +2242,7 @@ int dm_bit_get_next(dm_bitset_t bs, int last_bit);
|
|||||||
int dm_bit_get_last(dm_bitset_t bs);
|
int dm_bit_get_last(dm_bitset_t bs);
|
||||||
int dm_bit_get_prev(dm_bitset_t bs, int last_bit);
|
int dm_bit_get_prev(dm_bitset_t bs, int last_bit);
|
||||||
|
|
||||||
#define DM_BITS_PER_INT (sizeof(int) * CHAR_BIT)
|
#define DM_BITS_PER_INT ((unsigned)sizeof(int) * CHAR_BIT)
|
||||||
|
|
||||||
#define dm_bit(bs, i) \
|
#define dm_bit(bs, i) \
|
||||||
((bs)[((i) / DM_BITS_PER_INT) + 1] & (0x1 << ((i) & (DM_BITS_PER_INT - 1))))
|
((bs)[((i) / DM_BITS_PER_INT) + 1] & (0x1 << ((i) & (DM_BITS_PER_INT - 1))))
|
||||||
|
Loading…
Reference in New Issue
Block a user