am e652b123: Make sure res is NULL if getaddrinfo fails.

Merge commit 'e652b123d2d65d40e5f51c0145cc453ea88631dc'

* commit 'e652b123d2d65d40e5f51c0145cc453ea88631dc':
  Make sure res is NULL if getaddrinfo fails.