SolidWallOfCode commented on a change in pull request #7606:
URL: https://github.com/apache/trafficserver/pull/7606#discussion_r602547590
##########
File path: proxy/logging/LogField.cc
##########
@@ -164,14 +165,14 @@ namespace
{
struct cmp_str {
bool
- operator()(ts::ConstBuffer a, ts::ConstBuffer b) const
+ operator()(std::string_view a, std::string_view b) const
{
- return ptr_len_casecmp(a._ptr, a._size, b._ptr, b._size) < 0;
+ return ptr_len_casecmp(a.data(), a.size(), b.data(), b.size()) < 0;
Review comment:
`strcasecmp` is overloaded for `string_view` and `TextView`, so don't
use `ptr_len_casecmp`. E.g.
```
return strcasecmp(a, b) == 0;
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]