Skip to content

fix(exprparser): panic in format() on negative replacement index (rebase of #6136) - #6140

Closed
louzt wants to merge 1 commit into
nektos:masterfrom
LOUST-PRO:pr-6136-rebased
Closed

fix(exprparser): panic in format() on negative replacement index (rebase of #6136)#6140
louzt wants to merge 1 commit into
nektos:masterfrom
LOUST-PRO:pr-6136-rebased

Conversation

@louzt

@louzt louzt commented Jul 28, 2026

Copy link
Copy Markdown

Summary

Fix panic in format() function when replacement index is negative (out of bounds access on underlying writer).

What

  • Bounds-check replacement index before write
  • Test covers negative index case

Rebase status

Rebased against current master (4f41128). Zero conflicts. Tests pass.

@mergify

mergify Bot commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

⚠️ The sha of the head commit of this PR conflicts with #6136. Mergify cannot evaluate rules on this PR. Once #6136 is merged or closed, Mergify will resume processing this PR. ⚠️

@louzt

louzt commented Jul 28, 2026

Copy link
Copy Markdown
Author

Closing this PR — I verified the index < 0 bounds check locally against act master HEAD 4f41128; the head commit is the same SHA as the still-active #6136 from @semx, so no added value in opening a duplicate. Thanks to the original author for the fix.

@louzt louzt closed this Jul 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants