Commit 818de48
authored
waitUntilExit: ignore RunLoop.run()'s return value (#4740)
* 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#L561 parent 2d23cf3 commit 818de48
File tree
2 files changed
+10
-7
lines changed- CoreFoundation/Base.subproj
- Sources/Foundation
2 files changed
+10
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1179 | 1179 | | |
1180 | 1180 | | |
1181 | 1181 | | |
1182 | | - | |
| 1182 | + | |
1183 | 1183 | | |
1184 | 1184 | | |
1185 | 1185 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1134 | 1134 | | |
1135 | 1135 | | |
1136 | 1136 | | |
1137 | | - | |
1138 | | - | |
1139 | | - | |
1140 | 1137 | | |
1141 | | - | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
1142 | 1142 | | |
1143 | | - | |
1144 | | - | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
1145 | 1148 | | |
1146 | 1149 | | |
1147 | 1150 | | |
| |||
0 commit comments