Skip to content

Commit

Permalink
eliminates dropped error
Browse files Browse the repository at this point in the history
Signed-off-by: Oleh Dokuka <[email protected]>
Signed-off-by: Oleh Dokuka <[email protected]>
  • Loading branch information
OlegDokuka committed Mar 28, 2022
1 parent 9a504a8 commit 571af15
Showing 1 changed file with 6 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -192,15 +192,17 @@ public void sendErrorAndClose(RSocketErrorException rSocketErrorException) {
t -> {
framesSaverDisposable.dispose();
activeReceivingSubscriber.dispose();
savableFramesSender.dispose();
savableFramesSender.onComplete();
savableFramesSender.cancel();
onConnectionClosedSink.tryEmitComplete();

onClose.tryEmitError(t);
},
() -> {
framesSaverDisposable.dispose();
activeReceivingSubscriber.dispose();
savableFramesSender.dispose();
savableFramesSender.onComplete();
savableFramesSender.cancel();
onConnectionClosedSink.tryEmitComplete();

final Throwable cause = rSocketErrorException.getCause();
Expand Down Expand Up @@ -253,7 +255,8 @@ void dispose(@Nullable Throwable e) {

framesSaverDisposable.dispose();
activeReceivingSubscriber.dispose();
savableFramesSender.dispose();
savableFramesSender.onComplete();
savableFramesSender.cancel();
onConnectionClosedSink.tryEmitComplete();

if (e != null) {
Expand Down

0 comments on commit 571af15

Please sign in to comment.