Avoid a race condition between seeking and stopping.