Fixed race conditions with immediately resolving dfds