convert atoi() to strtol() to handle hex notations