From 764d5ed7d8d55c4c35a4524f5b2a7976a4b85c87 Mon Sep 17 00:00:00 2001 From: Thomas Schoebel-Theuer Date: Tue, 9 Jul 2013 18:50:18 +0200 Subject: [PATCH] infra: fix reference counter in lib_mapfree --- kernel/lib_mapfree.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/lib_mapfree.c b/kernel/lib_mapfree.c index ed69c0f9..6e495250 100644 --- a/kernel/lib_mapfree.c +++ b/kernel/lib_mapfree.c @@ -190,6 +190,7 @@ struct mapfree_info *mapfree_get(const char *name, int flags) MARS_WRN("race on creation of '%s' detected\n", name); _mapfree_put(mf); mf = _mf; + atomic_inc(&mf->mf_count); goto leave; } }