dworkin / dgd

Dworkin's Game Driver, an object-oriented database management system originally used to run MUDs.
https://www.dworkin.nl/dgd/
GNU Affero General Public License v3.0
103 stars 31 forks source link

Possible fix for upgrade+destruct memory leak #45

Closed nyankers closed 3 years ago

nyankers commented 3 years ago

It looks like this condition was added to prevent multiple reference deletions, but Object::remove() should already handle this (by grabbing the upgraded control), and the condition is preventing upgraded-then-destructed objects from freeing inheritance references as well as keeping the original object (not the copy created by ::upgrade()) from getting fully cleaned in ::clean() as ::remove() is what adds the object to baseplane.destruct.

nyankers commented 3 years ago

Possible solution for #44, or at least it should highlight the problem area if it's no good.