I'd prefer this were more robust and perhaps used a regexp.
Numerically sort lines containing ip addresses.