Skip to content

ICU-22775 fix StringSearch pattern CE mem mgmt #3606

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

markusicu
Copy link
Member

  • the main bug in Java initializePatternPCETable() was that the pcetablesize never got updated
  • in C++, if the pattern CE loops encountered a failure, they didn't free the array (unlikely but possible near OOM)
  • I think I made the memory management less convoluted
  • for good measure, I used the "append" functions to add the null terminator, rather than rely on these functions having over-allocated by one for the real collation elements

Checklist

  • Required: Issue filed: ICU-22775
  • Required: The PR title must be prefixed with a JIRA Issue number. Example: "ICU-1234 Fix xyz"
  • Required: Each commit message must be prefixed with a JIRA Issue number. Example: "ICU-1234 Fix xyz"
  • Issue accepted (done by Technical Committee after discussion)
  • Tests included, if applicable
  • API docs and/or User Guide docs changed or added, if applicable

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