[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-dev] Re: Still occasional memory corruption...



On Nov 20, 2013 6:18 PM, "James Harkins" <jamshark70@xxxxxxxxx> wrote:
> Wait... here it is... the error happens in collectAs. My call stack shows that the "class" argument is Array, and one item is successfully added into the array. By the time it gets to the second iteration, somehow "res" has changed from an array to a TempoClock, despite the fact that res IS NEVER REASSIGNED in this method! That is, function.value(elem, i) has had a side effect in a scope to which that function has NO ACCESS.

Another (likely more plausible) explanation is stack corruption. I just remembered that the stack trace shows res is still an array. So, probably when the VM gets around to sending the message "add," it gets the clock off the stack instead of what ought to be the receiver.

Either way, not good.

hjh