Skip to content

refactor JPEGFactory.createFromStream one more time - #511

Closed
valerybokov wants to merge 1 commit into
apache:trunkfrom
valerybokov:refactor-JPEGFactory.createFromStream_one_more_time
Closed

refactor JPEGFactory.createFromStream one more time#511
valerybokov wants to merge 1 commit into
apache:trunkfrom
valerybokov:refactor-JPEGFactory.createFromStream_one_more_time

Conversation

@valerybokov

Copy link
Copy Markdown

I discovered a problem with the current code. It involves using the InputStream.mark method with an Integer.MAX_VALUE parameter. When using this value, BufferedInputStream can allocate an array of length Integer.MAX_VALUE. This negatively impacts memory usage.

asf-gitbox-commits pushed a commit that referenced this pull request Aug 30, 2026
asf-gitbox-commits pushed a commit that referenced this pull request Aug 30, 2026
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