Skip to content

Commit

Permalink
Cancel subscription when buffer gets freed
Browse files Browse the repository at this point in the history
  • Loading branch information
malhotrashivam committed Jun 21, 2024
1 parent e293af1 commit 6a0da89
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,7 @@ public void onNext(final ByteBuffer dataBuffer) {
final ByteBuffer resultBuffer = S3Request.this.get();
if (resultBuffer == null) {
localProducer.complete(false);
subscription.cancel();
return;
}
final int numBytes = dataBuffer.remaining();
Expand Down

0 comments on commit 6a0da89

Please sign in to comment.