Boost logo

Boost Users :

Subject: [Boost-users] asio tcp::resolver, service resolution
From: Lloyd (lloydkl.tech_at_[hidden])
Date: 2011-08-25 11:21:21


Hi,

In documentation I saw that using tcp::resolver::query constructor it
is possible to resolve domain.name as well as service name, as shown
in the following code fragment.

boost::asio::io_service ios;
boost::asio::ip::tcp::resolver resolver(ios);
boost::asio::ip::tcp::resolver::query query("mydomain.com","myservice");

Here 'myservice' is not a well known service (port number).

For resolving 'myservice' where should I add the port number? in my
domain name server's (BIND) /etc/services file or in my local systems
services file?

Or is it 'really' possible to resolve a service name?

Thanks,
  Lloyd


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net