Improved throwing InvalidExitValueException.