IPv4 string to int convert functon