> <i>The new process [ls -l] gets the desired data, sends it to the shell and terminates.</i><p>> <i>The shell sends the data to the terminal through the STDOUT side of the pty</i><p>Unless redirected, ls inherits the pty file descriptor from the shell¹ when the shell forks it. But after that, it's writing to the terminal emulator directly, not to the shell; that is, the shell doesn't forward `ls -l`'s output to the terminal.<p>¹(or really, the child inherits whatever file descriptor the shell has for stdin, stdout, stderr for its stdin, stdout, stderr, respectively, unless, for each of those, there is a redirection specified, in which case the shell replaces the file descriptor in the child as specified by the command give to the shell. stdin/stdout/stderr might be a pty in the shell, or they might not be.)