Debugging wierd infinite loop.