Skip to content

Commit f046d60

Browse files
committed
fix(lib-storage): ignore overall data content-length for UploadPart operation
1 parent 2cd16c2 commit f046d60

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/lib-storage/src/Upload.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,9 @@ export class Upload extends EventEmitter {
276276
const partResult = await this.client.send(
277277
new UploadPartCommand({
278278
...this.params,
279-
ContentLength: partSize || undefined,
279+
// dataPart.data is chunked into a non-streaming buffer
280+
// so the ContentLength from the input should not be used for MPU.
281+
ContentLength: undefined,
280282
UploadId: this.uploadId,
281283
Body: dataPart.data,
282284
PartNumber: dataPart.partNumber,

0 commit comments

Comments
 (0)