mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-04-22 06:55:53 +00:00
CLEANUP: cache: Use proper data types in secondary_key_cmp()
- hash_length is `unsigned int` and so should offset. - idx is compared to a `size_t` and thus it should also be.
This commit is contained in:
parent
1d66e396bf
commit
5897cfe18e
@ -208,8 +208,8 @@ struct cache_entry *entry_exist(struct cache *cache, char *hash)
|
|||||||
static int secondary_key_cmp(const char *ref_key, const char *new_key)
|
static int secondary_key_cmp(const char *ref_key, const char *new_key)
|
||||||
{
|
{
|
||||||
int retval = 0;
|
int retval = 0;
|
||||||
int idx = 0;
|
size_t idx = 0;
|
||||||
int offset = 0;
|
unsigned int offset = 0;
|
||||||
const struct vary_hashing_information *info;
|
const struct vary_hashing_information *info;
|
||||||
|
|
||||||
for (idx = 0; idx < sizeof(vary_information)/sizeof(*vary_information) && !retval; ++idx) {
|
for (idx = 0; idx < sizeof(vary_information)/sizeof(*vary_information) && !retval; ++idx) {
|
||||||
|
Loading…
Reference in New Issue
Block a user