| 854 | |
| 855 | namespace { |
| 856 | bool parse_no_port(const ConfigPair& sample, NetworkAddress& retval, const NetworkAddress& value) |
| 857 | { |
| 858 | ACE_INET_Addr addr; |
| 859 | if (addr.set(u_short(0), sample.value().c_str()) == 0) { |
| 860 | retval = NetworkAddress(addr); |
| 861 | return true; |
| 862 | } else { |
| 863 | retval = value; |
| 864 | if (log_level >= LogLevel::Warning) { |
| 865 | ACE_ERROR((LM_WARNING, |
| 866 | ACE_TEXT("(%P|%t) WARNING: ConfigStoreImpl::get: ") |
| 867 | ACE_TEXT("failed to parse NetworkAddress for %C=%C\n"), |
| 868 | sample.key().c_str(), sample.value().c_str())); |
| 869 | } |
| 870 | } |
| 871 | return false; |
| 872 | } |
| 873 | |
| 874 | bool parse_port(const ConfigPair& sample, NetworkAddress& retval, const NetworkAddress& value) |
| 875 | { |