Fixed segfaults in subshell commands.