| 152 | } |
| 153 | |
| 154 | const char* master_service::get_addr(const char* from) const |
| 155 | { |
| 156 | if (from == NULL || *from == 0) { |
| 157 | return NULL; |
| 158 | } |
| 159 | acl::string key(from); |
| 160 | key.lower(); |
| 161 | std::map<acl::string, acl::string>::const_iterator cit = |
| 162 | addrs_map_.find(key); |
| 163 | if (cit != addrs_map_.end()) { |
| 164 | return cit->second.c_str(); |
| 165 | } else { |
| 166 | logger("Local not exist from: %s\r\n", from); |
| 167 | return NULL; |
| 168 | } |
| 169 | } |
| 170 | |
| 171 | void master_service::create_addrs_map() |
| 172 | { |