This is the real bug, Apache shouldn't be second-guessing getaddrinfo, APR's call_resolver is an excellent example of how to do it properly, AI_ADDRCONFIG is the key. Trouble is apr_sockaddr_info_get isnt calling it for us. This is an APR bug, see the attached patch.
Okay, I just committed variants of your patch to CVS that work for me on Solaris. The biggest gotcha was setting servname to be non-NULL when hostname was NULL.
Thanks! -- justin