change logic for first thread to prevent lockout