Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm
diff options
context:
space:
mode:
authorXavier Chantry <chantry.xavier@gmail.com>2011-04-02 20:24:40 +0200
committerDan McGee <dan@archlinux.org>2011-04-04 23:35:39 -0500
commitff1974c6e9aa97a6b0cf5e2ce82da70fd70c510c (patch)
tree7ec9b86c73d777114e64678b379c11e0da0afdf7 /lib/libalpm
parent40fd8123a292ad16610367922dbdff66460bc676 (diff)
libalpm/pkghash.c: unused variable ptr
spotted by clang analyzer Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Diffstat (limited to 'lib/libalpm')
-rw-r--r--lib/libalpm/pkghash.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/libalpm/pkghash.c b/lib/libalpm/pkghash.c
index db98f94b..6dc43243 100644
--- a/lib/libalpm/pkghash.c
+++ b/lib/libalpm/pkghash.c
@@ -84,12 +84,11 @@ pmpkghash_t *_alpm_pkghash_create(size_t size)
static size_t get_hash_position(unsigned long name_hash, pmpkghash_t *hash)
{
size_t position;
- alpm_list_t *ptr;
position = name_hash % hash->buckets;
/* collision resolution using open addressing with linear probing */
- while((ptr = hash->hash_table[position]) != NULL) {
+ while(hash->hash_table[position] != NULL) {
position = (position + 1) % hash->buckets;
}