Handles basic terminating errors, outputs to an error log