We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 453e6f5 commit 70e93e0Copy full SHA for 70e93e0
lib/auth/streamingV4/trailingChecksumTransform.js
@@ -66,7 +66,8 @@ class TrailingChecksumTransform extends Transform {
66
}
67
68
// we are now looking for the chunk size field
69
- // no need to look further than 10 bytes since the field cannot be bigger
+ // no need to look further than 10 bytes since the field cannot be bigger: the max
70
+ // chunk size is 5GB (see constants.maximumAllowedPartSize)
71
const lineBreakIndex = chunk.subarray(0, 10).indexOf('\r');
72
const bytesToKeep = lineBreakIndex === -1 ? chunk.byteLength : lineBreakIndex;
73
if (this.chunkSizeBuffer.byteLength + bytesToKeep > 10) {
0 commit comments