Added support for stdout and stderr redirestion to Erlang