Skip to content

[tmva][sofie] Avoid undefined behavior in Clean_name - #23158

Merged
guitargeek merged 1 commit into
root-project:masterfrom
Yongyanliu65:patch-1
Aug 28, 2026
Merged

guitargeek merged 1 commit into
root-project:masterfrom
Yongyanliu65:patch-1

Conversation

@Yongyanliu65

Copy link
Copy Markdown
Contributor

Summary

Cast the character passed to std::isalnum to unsigned char in
UTILITY::Clean_name.

Passing a negative char directly to the <cctype> classification
functions can result in undefined behavior.

@Yongyanliu65
Yongyanliu65 requested a review from lmoneta as a code owner August 26, 2026 15:11
@guitargeek guitargeek closed this Aug 27, 2026
@guitargeek guitargeek reopened this Aug 27, 2026
@github-actions

Copy link
Copy Markdown

Test Results

    22 files      22 suites   3d 14h 52m 11s ⏱️
 3 859 tests  3 858 ✅ 0 💤 1 ❌
75 774 runs  75 773 ✅ 0 💤 1 ❌

For more details on these failures, see this check.

Results for commit 5d74917.

@guitargeek guitargeek left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks. But again, please group multiple of these small fixes in one commit, for the future.

@guitargeek
guitargeek merged commit 150ce90 into root-project:master Aug 28, 2026
30 of 34 checks passed
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.

2 participants