Skip to content

Conversation

@sashwinbalaji
Copy link
Member

No description provided.

Pass std::string_view to MurmurHashCombiner instead of (ptr, size).
The previous code was calling hasher.Combine(ptr, size), which was
interpreted as two separate calls to CombineOne(). The first call
CombineOne(const char*) was invoking the std::string_view(const char*)
constructor, which calls strlen(). Since trace buffer slices are not
null-terminated, this resulted in a SEGV.

Using std::string_view(ptr, size) ensures that the size is explicitly
passed and strlen() is avoided.

Bug: b/477506828
@github-actions
Copy link

🎨 Perfetto UI Build

✅ UI build is ready: https://storage.googleapis.com/perfetto-ci-artifacts/gh-21220957982-1-ui/ui/index.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant