mirror of
https://salsa.debian.org/ha-team/libqb
synced 2026-08-08 20:07:21 +00:00
Fixed bug: incorrect array length definition
When MAX_BINS is larger than MAX_BIN_ELEMENTS, this bug will cause boudary overflow in qb_array_create function. Signed-off-by: Yunkai Zhang <qiushu.zyk@taobao.com> Signed-off-by: Angus Salkeld <asalkeld@redhat.com>
This commit is contained in:
parent
d823a480dc
commit
c8e97a1c2e
@ -29,7 +29,7 @@
|
||||
#define ELEM_NUM_GET(_idx_) (_idx_ & 0xff)
|
||||
|
||||
struct qb_array {
|
||||
void *bin[MAX_BIN_ELEMENTS];
|
||||
void *bin[MAX_BINS];
|
||||
size_t max_elements;
|
||||
size_t element_size;
|
||||
size_t num_bins;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user