Closing std handles (but without redirecting them) allows kernel to "reuse" 0,1, 2 file handle ids for subsequent file handle open operations.
This issue may lead to junk data sent over TCP connection from lldb-gdbserver to lldb because stderr file handle might be assigned to the socket handle:
int fd = connection_up->GetReadObject()->GetWaitableHandle();
assert(fd == STDERR_FILENO); // llgs doesn't crash on such assertion without this code change in.
By redirecting std handles to /dev/null we prevent OS from such std handles reuse.