Skip to content

Conversation

@iCharlesHu
Copy link
Contributor

No description provided.

* waitUntilExit: ignore RunLoop.run()'s return value

We've been seeing frequent (but not reproducible in isolation) failures
in our builds where waitUntilExit returns but terminationStatus fails
its precondition on hasFinished because isRunning is still true.
This is a speculative fix, since I haven't been able to reproduce the
failure in a self-contained test.

This should be safe since Process.waitUntilExit isn't spec'd to relate
to RunLoop. In particular there is no guarantee that "stopping" a
RunLoop should cause waitUntilExit to return before the monitored
process has exited.

* Exclude libdispatch_init() on TARGET_OS_MAC because it duplicates the call from the static constructor https://github.com/apple/swift-corelibs-libdispatch/blob/7fb9d5ceea562d60fe34ec55b6b165ae5aca38eb/src/init.c#L56
@MaxDesiatov
Copy link
Contributor

@swift-ci test

@shahmishal
Copy link
Member

@swift-ci test macOS

@briancroom
Copy link
Contributor

@swift-ci test

@iCharlesHu iCharlesHu merged commit 5721010 into swiftlang:release/5.9 Sep 11, 2023
@iCharlesHu iCharlesHu deleted the charles/runloop branch September 11, 2023 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants