reuse same code for setting pipes in run/exec Upstream-commit: c26695cf8a220bf33ba0efe729e2ab4b05089ea8 Component: engine