Fix another race condition