Skip to content

Commit

Permalink
Fix memory leak when using ktor-client-java (open-telemetry#4637)
Browse files Browse the repository at this point in the history
  • Loading branch information
laurit authored and RashmiRam committed May 23, 2022
1 parent 773feb4 commit 0906ba2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public BodySubscriber<T> apply(ResponseInfo responseInfo) {
if (subscriber instanceof BodySubscriberWrapper) {
return subscriber;
}
return new BodySubscriberWrapper<>(delegate.apply(responseInfo), context);
return new BodySubscriberWrapper<>(subscriber, context);
}

public static class BodySubscriberWrapper<T> implements BodySubscriber<T> {
Expand Down

0 comments on commit 0906ba2

Please sign in to comment.