more fixing up of call to thread_exit from swapper