added exceptions for atoi