When piping the output in for eg. `head -n 1`, the `head` utility might close down the pipe at some point, yielding a broken pipe error. We catch that and simply return if that's the case.