My goodness, I'm sure a million forum topics on this have been created, but I can't find any that address the specific problem I'm having.
In my game, I am detecting a collision between two collision types. When this occurs, my collision handler tells one of the objects to destroy itself, and in its destruction method I have a cpSpaceAddPostStepCallback call to remove the object's physics objects. Shortly thereafter, the callback is called and the space is locked, so it says to use a post step callback...which I am.
My physics post step callback is called removePhysicsCallBack
My runtime stack looks like this:
#0 0x921c89c6 in __pthread_kill ()
#1 0x9012df78 in pthread_kill ()
#2 0x9011ebdd in abort ()
#3 0x00064c98 in cpMessage at /<redacted>/chipmunk.c:44
#4 0x0007c5b7 in cpSpaceRemoveBody ()
#5 0x0003561d in removePhysicsCallBack ()
#6 0x00081e34 in postStepCallbackSetIter ()
#7 0x00076b67 in cpHashSetEach ()
#8 0x00081683 in cpSpaceStep at /Users/<redacted>/Chipmunk/src/cpSpaceStep.c:398