]> git.ipfire.org Git - thirdparty/systemd.git/commit - src/basic/hashmap.c
hashmap: return NULL from destructor
authorDavid Herrmann <dh.herrmann@gmail.com>
Fri, 10 Apr 2015 09:15:12 +0000 (11:15 +0200)
committerDavid Herrmann <dh.herrmann@gmail.com>
Sat, 11 Apr 2015 11:14:41 +0000 (13:14 +0200)
commitcfe561a456c9ce61579c8e1207f9a13faf050e8a
treeceeee398eb419196e9b2a078f374da232a8698e4
parent07ba8037bf2a2d6a683fa107ee6f2b9545fca23e
hashmap: return NULL from destructor

We _always_ return NULL from destructors to allow direct assignments to
the variable holding the object. Especially on hashmaps, which treat NULL
as empty hashmap, this is pretty neat.
src/shared/hashmap.c
src/shared/hashmap.h