You are releasing p, then setting it to null so you are basically removing p then readding it with a value of null.
As far as I can tell (docs dont explain properly) setting to null is only done with an object reference and release is done with variables.
I might be wrong, but id suggest removing p=null and release p. Once you assign p to another object, flushmem should see that the object it referenced is now dead with no links.
As far as I can tell (docs dont explain properly) setting to null is only done with an object reference and release is done with variables.
I might be wrong, but id suggest removing p=null and release p. Once you assign p to another object, flushmem should see that the object it referenced is now dead with no links.