Set exit status code to 1 if error occurred.

Fixes #95.