Skip to content

fixes #8001 Fix RandomAccessFile leak in FilePool.close()#8002

Open
iamsanjaymalakar wants to merge 1 commit intopayara:mainfrom
iamsanjaymalakar:issue-8001
Open

fixes #8001 Fix RandomAccessFile leak in FilePool.close()#8002
iamsanjaymalakar wants to merge 1 commit intopayara:mainfrom
iamsanjaymalakar:issue-8001

Conversation

@iamsanjaymalakar
Copy link

Description

Fix resource cleanup in RandomAccessDataFile.FilePool#close().
If closing one pooled RandomAccessFile throws an IOException, the current loop exits early and remaining pooled files may remain unclosed. This change continues closing the rest and then rethrows the first exception (with subsequent ones suppressed).

Addresses: #8001

Important Info

Blockers

None.

Testing

New tests
None.

Built the affected module locally.

Notes for Reviewers

Change is limited to FilePool#close() and only affects the failure path when RandomAccessFile.close() throws.

@Pandrex247 Pandrex247 added the PR: Awaiting CLA Contributor does not have a CLA or has submitted an unconfirmed CLA. label Mar 12, 2026
@iamsanjaymalakar
Copy link
Author

Emailed the signed CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: Awaiting CLA Contributor does not have a CLA or has submitted an unconfirmed CLA.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants