diff options
author | Ignacio Galarza <iggy@mysql.com> | 2009-02-13 11:41:47 -0500 |
---|---|---|
committer | Ignacio Galarza <iggy@mysql.com> | 2009-02-13 11:41:47 -0500 |
commit | 5b7347bda31b9d66cd78937e5dc339f553b9a736 (patch) | |
tree | 85b39362efeae16536a90f3a3624acd6916d4305 /mysys/hash.c | |
parent | 50b19265ffcf4e4708c86345a5c166c58dbdb523 (diff) | |
parent | 54fbbf9591e21cda9f7b26c2d795d88f51827f07 (diff) | |
download | mariadb-git-5b7347bda31b9d66cd78937e5dc339f553b9a736.tar.gz |
Bug#29125 Windows Server X64: so many compiler warnings
- Remove bothersome warning messages. This change focuses on the warnings
that are covered by the ignore file: support-files/compiler_warnings.supp.
- Strings are guaranteed to be max uint in length
Diffstat (limited to 'mysys/hash.c')
-rw-r--r-- | mysys/hash.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/mysys/hash.c b/mysys/hash.c index dd2d589e509..0b44782aeb5 100644 --- a/mysys/hash.c +++ b/mysys/hash.c @@ -157,14 +157,14 @@ my_hash_key(const HASH *hash, const uchar *record, size_t *length, /* Calculate pos according to keys */ -static uint my_hash_mask(uint hashnr, uint buffmax, uint maxlength) +static uint my_hash_mask(size_t hashnr, size_t buffmax, size_t maxlength) { if ((hashnr & (buffmax-1)) < maxlength) return (hashnr & (buffmax-1)); return (hashnr & ((buffmax >> 1) -1)); } static uint my_hash_rec_mask(const HASH *hash, HASH_LINK *pos, - uint buffmax, uint maxlength) + size_t buffmax, size_t maxlength) { size_t length; uchar *key= (uchar*) my_hash_key(hash, pos->data, &length, 0); @@ -309,8 +309,7 @@ static int hashcmp(const HASH *hash, HASH_LINK *pos, const uchar *key, my_bool my_hash_insert(HASH *info, const uchar *record) { int flag; - size_t idx; - uint halfbuff,hash_nr,first_index; + size_t idx,halfbuff,hash_nr,first_index; uchar *ptr_to_rec,*ptr_to_rec2; HASH_LINK *data,*empty,*gpos,*gpos2,*pos; @@ -539,8 +538,8 @@ exit: my_bool my_hash_update(HASH *hash, uchar *record, uchar *old_key, size_t old_key_length) { - uint new_index,new_pos_index,blength,records,empty; - size_t idx; + uint new_index,new_pos_index,blength,records; + size_t idx,empty; HASH_LINK org_link,*data,*previous,*pos; DBUG_ENTER("my_hash_update"); |