--
---
You received this message because you are subscribed to the Google Groups "nhibernate-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-develo...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-development+unsub...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-develo...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-development+unsubscri...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-develo...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-develo...@googlegroups.com.
Here's the patch:Unfortunately, even with that patch applied, the unit test in my other post fails -- even though a heap inspection with WinDBG confirms that the session is no longer rooted and is eligible for collection.
Unfortunately, even with that patch applied, the unit test in my other post fails -- even though a heap inspection with WinDBG confirms that the session is no longer rooted and is eligible for collection.My attempts with dubious knowledge of Windbg seems to confirm that the test itself did indeed maintain a reference to the SessionImpl instance, as a local variable in the stack fram of IsGarbageCollected<TObject>(ref TObject @object, Action<TObject> useObject). I don't know how to explain that, given that the test code attempted to nullify the reference.
On Saturday, January 18, 2014 11:44:53 PM UTC+2, Oskar Berggren wrote:Unfortunately, even with that patch applied, the unit test in my other post fails -- even though a heap inspection with WinDBG confirms that the session is no longer rooted and is eligible for collection.
My attempts with dubious knowledge of Windbg seems to confirm that the test itself did indeed maintain a reference to the SessionImpl instance, as a local variable in the stack fram of IsGarbageCollected<TObject>(ref TObject @object, Action<TObject> useObject). I don't know how to explain that, given that the test code attempted to nullify the reference.
The second GC.Collect() pass fixed that for me, like Gunnar suggested. I'll take another look at it soon-ish to see if your modified test still behaves the way I think it should.
My first attempt at a fix actually was to discard the _expression reference. However, that didn't work -- IIRC because the results of the translation maintained another reference to the expression. Changing that would have had a considerably bigger change footprint, one that I wasn't comfortable with.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-development+unsub...@googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "nhibernate-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nhibernate-development+unsub...@googlegroups.com.