fix locking error with current_tb