]> xenbits.xensource.com Git - libvirt.git/commit
util: Simplify hash implementation
authorJiri Denemark <jdenemar@redhat.com>
Tue, 12 Apr 2011 17:12:12 +0000 (19:12 +0200)
committerJiri Denemark <jdenemar@redhat.com>
Wed, 27 Apr 2011 13:32:30 +0000 (15:32 +0200)
commit1671d1dc781dcf3147ec20f915bcc18461ab119b
treef98687921df56185be550fda2de5a39b6a21ae08
parent91e12a50949271a7c805ffb2548eff257835fc1e
util: Simplify hash implementation

So far first entries for each hash key are stored directly in the hash
table while other entries mapped to the same key are linked through
pointers. As a result of that, the code is cluttered with special
handling for the first items.

This patch makes all entries (even the first ones) linked through
pointers, which significantly simplifies the code and makes it more
maintainable.
src/util/hash.c