I have a shell script that saves the output of a command that is executed to a CSV file. It reads the command it has to execute from a shell script which is in this format:
ffmpeg reads STDIN and exhausts it. The solution is to call ffmpeg with:
ffmpeg
See the detailed explanation here: http://mywiki.wooledge.org/BashFAQ/089