fix bug in RemoveFromWaitingJobs. atg.