If the errexit option is set in bash, the subprocess will silently die when there is an error. So it prevents further execution. This becomes required to overcome this and allow us to catch the return code etc.