dahlia/wand — pull request #59 by henninge (2012-09-18 16:00:01+00:00)
Title: Add missing decrement_refcount

I am not sure why nobody has noticed it before but I guess it is because I had a logger configured that would output the log messages issued in increment_refcount and decrement_refcount. I got kind of worried when I saw the ref count go up and up...

The fix is simple: While the resource.setter calls increment_refcount() its counterpart resource.deleter did not call decrement_recount(). I fixed that by adding the latter call.

I also have the suspicion, though, that calling increment_refcount() in the setter is wrong in the first place since it overlaps with allocate(). At least I see that all the log messages are in pairs, two increments, two decrements. If that is ok, though, then this branch is your fix. ;-)