Skip to content

Conversation

@caolanm
Copy link

@caolanm caolanm commented Oct 10, 2025

echo | mergefonts -cid tests/mergefonts_data/input/cidwhitespace/cidfontinfo.txt Segmentation fault (core dumped)

As a minimal fix if the start/end searchs are swapped so that the search for the end of whitespace is done before searching for the start then the new null terminator set by the end search will stop the start search going past the buffer end.

Description

Replace this text with a description of your changes, indicating whether
it is a bug fix, enhancement, etc. and which general area(s) are affected
(documentation, specific tool, group of tools, tests, etc.).

If the contribution closes (fixes, resolves) a specific open
issue, please link
the issue
.

Checklist:

  • I have followed the Contribution Guidelines
  • I have added test code and data to prove that my code functions correctly
  • I have verified that new and existing tests pass locally with my changes
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation

echo | mergefonts -cid tests/mergefonts_data/input/cidwhitespace/cidfontinfo.txt
Segmentation fault (core dumped)

As a minimal fix if the start/end searchs are swapped so that the search
for the end of whitespace is done before searching for the start then
the new null terminator set by the end search will stop the start search
going past the buffer end.
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