windows XP threads: fix hilariously obvious race