Boris | 1 Sep 13:19
Picon

Re: [Boost.Asio] service_name/port inconsistency

On Mon, 01 Sep 2008 05:20:43 +0200, Vjekoslav Brajkovic  
<balkan <at> cs.washington.edu> wrote:

> On Sun, 31 Aug 2008, Boris wrote:
>
>>> [...]a) What is the point passing endpoint_type, when we know for sure  
>>> that
>>> endpoint will only accept address which *cannot* be a FQDN. What do we
>>> achieve by doing this?
>>
>> If I'm not mistaken it's basically a wrapper for getnameinfo().
>
> Maybe I haven't expressed myself correctly.
>
> resolver.resolve(endpoint) - does not resolve anything since the  
> endpoint can only be expressed in dotted decimal form, or in hexadecimal
> notation.

I think I haven't expressed myself correctly. :)

If you look at asio/detail/resolver_service.hpp and search for getnameinfo  
you'll see that the endpoint is resolved (which means a host name and  
service name is returned; see  
http://msdn.microsoft.com/en-us/library/ms738532(VS.85).aspx).

Boris

Gmane