hashmap_put takes "struct hashmap_entry *"

This is less error-prone than "void *" as the compiler now
detects invalid types being passed.

Signed-off-by: Eric Wong <e@80x24.org>
Reviewed-by: Derrick Stolee <stolee@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Eric Wong
2019-10-06 23:30:32 +00:00
committed by Junio C Hamano
parent 28ee794128
commit 26b455f21e
11 changed files with 15 additions and 12 deletions

View File

@ -51,5 +51,5 @@ void *oidmap_put(struct oidmap *map, void *entry)
oidmap_init(map, 0);
hashmap_entry_init(&to_put->internal_entry, oidhash(&to_put->oid));
return hashmap_put(&map->map, to_put);
return hashmap_put(&map->map, &to_put->internal_entry);
}