| 385 | } |
| 386 | |
| 387 | size_t RestfulMap::RemoveByPathString(const std::string& path) { |
| 388 | // removal only happens when server stops, clear _sorted_paths to make |
| 389 | // sure wild pointers do not exist. |
| 390 | if (!_sorted_paths.empty()) { |
| 391 | _sorted_paths.clear(); |
| 392 | } |
| 393 | return _dedup_map.erase(path); |
| 394 | } |
| 395 | |
| 396 | struct PrefixLess { |
| 397 | bool operator()(const butil::StringPiece& path, |
no test coverage detected