Skip to content
This repository was archived by the owner on Nov 15, 2022. It is now read-only.

Commit 1365c33

Browse files
jayasheelankumaryaminikb
authored andcommitted
Fixes #21992: Fixed buffer size in MultipartStream (#22077)
1 parent 347427c commit 1365c33

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

appserver/web/web-core/src/main/java/org/apache/catalina/fileupload/MultipartStream.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ private void notifyListener() {
353353
}
354354

355355
this.input = input;
356-
this.bufSize = bufSize;
356+
this.bufSize = Math.max(bufSize, boundaryLength * 2);
357357
this.buffer = new byte[bufSize];
358358
this.notifier = pNotifier;
359359

0 commit comments

Comments
 (0)