mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
If execv fails, then there is no valid indication of what failed. This may manifest itself as an unexpected EOF in `collectBytesFromPipe` when in fact this is a problem with `execv`. Check the return status and be noisy if the exec fails. Now, on other platforms, it may not be a runtime error to call `execv(..., NULL)`, despite the manual pages and standards requesting that a valid array be passed. Furthermore, other platforms may require that argv[0] be populated, and with a valid executable name. Ensuring that these conditions are fulfilled is more correct, and permits the Reflection validation tests to successfully run and pass on OpenBSD.
25 KiB
25 KiB