initialize errno to 0 before strtoul call