Skip to content

fix(op-preimage): preserve read and write close errors#21597

Open
blackflytech wants to merge 1 commit into
ethereum-optimism:developfrom
blackflytech:develop
Open

fix(op-preimage): preserve read and write close errors#21597
blackflytech wants to merge 1 commit into
ethereum-optimism:developfrom
blackflytech:develop

Conversation

@blackflytech

Copy link
Copy Markdown

Description

Fixes ReadWritePair.Close so it preserves close errors from both the reader and writer.

Previously, if closing both files failed, the writer close error replaced the reader close error. This change joins each close error into the accumulated error so callers can see both failures.

Tests

  • go test ./op-preimage
  • git diff --check

Additional context

This is a small, focused fix with a regression test. It follows the same low-risk pattern as #21480: narrow scope, clear motivation, and simple local verification.

Metadata

Signed-off-by: blackflytech <blackflytech@outlook.com>
@blackflytech blackflytech requested a review from a team as a code owner June 29, 2026 17:21
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