commit | c6609efc0fdcb1705cf157b4f383152edb7505c6 | [log] [tgz] |
---|---|---|
author | Patrick McHardy <kaber@trash.net> | Wed Jan 09 19:41:58 2008 +0100 |
committer | Thomas Graf <tgr@deb.localdomain> | Thu Jan 10 12:44:22 2008 +0100 |
tree | 30009e53604c150d49ca14867e5844756b1389ac | |
parent | c8a0a5cdfba51f7de5d203aa13a97377b215515a [diff] |
[PATCH] libnl cache management leak
diff --git a/lib/cache.c b/lib/cache.c index c1fbea6..285bc31 100644 --- a/lib/cache.c +++ b/lib/cache.c
@@ -505,8 +505,11 @@ old = nl_cache_search(cache, obj); if (old) { nl_cache_remove(old); - if (type->mt_act == NL_ACT_DEL && cb) - cb(cache, old, NL_ACT_DEL); + if (type->mt_act == NL_ACT_DEL) { + if (cb) + cb(cache, old, NL_ACT_DEL); + nl_object_put(old); + } } if (type->mt_act == NL_ACT_NEW) {