isdigit() and atoi() take different types of parameter. The first takes an int; the second takes a string.
You passing argv[2] to both functions. At least one of the calls is wrong.