Fix segfault on failure to add peer specified by IP address.