Add stdout thread.