Skip to content

Commit

Permalink
Reduce variable scope - mutt/hash.c
Browse files Browse the repository at this point in the history
  • Loading branch information
fekir authored and flatcap committed Mar 6, 2018
1 parent 0e1b205 commit 9a93188
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions mutt/hash.c
Original file line number Diff line number Diff line change
Expand Up @@ -189,11 +189,10 @@ static struct HashElem *union_hash_insert(struct Hash *table, union HashKey key,
else
{
struct HashElem *tmp = NULL, *last = NULL;
int r;

for (tmp = table->table[h], last = NULL; tmp; last = tmp, tmp = tmp->next)
{
r = table->cmp_key(tmp->key, key);
const int r = table->cmp_key(tmp->key, key);
if (r == 0)
{
FREE(&ptr);
Expand Down

0 comments on commit 9a93188

Please sign in to comment.