Boost logo

Boost Users :

Subject: Re: [Boost-users] [asio] negating address_configured
From: Igor R (boost.lists_at_[hidden])
Date: 2011-03-04 06:37:38


> What is the correct way to negate the (default) resolver flag,
> address_configured?
>
> On Windows, at least, specifying address_configured (which translates to
> AI_ADDRCONFIG) has a nasty side effect.  If the 'external' network is down,
> the resolver can no longer resolve the "localhost" address.  More here
> http://src.chromium.org/viewvc/chrome/trunk/src/net/base/host_resolver.cc?r1=16212&r2=16211

Well, I know nothing about this flag, but in asio sources we find the following:

# if defined(AI_ADDRCONFIG) && !defined(__QNXNTO__)
    address_configured = AI_ADDRCONFIG
# else
    address_configured = 0
# endif

So can you just #define AI_ADDRCONFIG 0 ?


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