The original code incorrectly used the stdout null check condition for both stdout and stderr pointer selection. This caused incorrect behavior when stderr is null but stdout is not, or vice-versa. This fix separates the null checks for stdout and stderr into independent conditions, ensuring each stream is properly selected based on its own null status. Generated with [codeagent](https://github.com/qbox/codeagent) Co-authored-by: cpunion <8459+cpunion@users.noreply.github.com>
6.5 KiB
6.5 KiB