On Sun, Mar 22, 2009 at 11:40 PM, Igor Stasenko siguctua@gmail.com wrote:
2009/3/22 Igor Stasenko siguctua@gmail.com:
2009/3/22 Michael van der Gulik mikevdg@gmail.com:
On Sun, Mar 22, 2009 at 4:55 PM, Michael van der Gulik <
mikevdg@gmail.com> wrote:
<snip> >>> Hi VM guys. >>> >>> Does anybody have any insights into the following?:
<bigger snip>
I've isolated the bug. To reproduce, do the following in a disposable
image:
Sensor primSetInputSemaphore: (Semaphore new).
self primSetInputSemaphore: (Smalltalk registerExternalObject:
inputSemaphore).
That of couse is not excuse for VM crash, when you passing a semaphore object intead of valid smallinteger index in external objects table. It should check and fail if you do so.
Thanks, Igor. I never was good at details.
When I next have time (Tuesday evening?) I'll submit a patch for this:
- rename primSetInputSemaphore: to primSetInputSemaphoreIndex:. - Add checks in the VM: must be a SmallInteger, must be a valid index in the external objects table, must point to a Semaphore. - Add error handling code in the method itself.
Gulik.