Fix a race with unmapping windows.