in reply to Regex to take an ip address before a comma

This can be as simple as splitting on the first comma and taking the first chunk.

Regexp::Common::net also provides regexes for parsing IPv4 addresses.

  • Comment on Re: Regex to take an ip address before a comma