File tree Expand file tree Collapse file tree 2 files changed +5
-2
lines changed
src/main/java/rx/internal/operators Expand file tree Collapse file tree 2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -98,7 +98,9 @@ public void request(long n) {
9898 }
9999
100100 if (!it .hasNext ()) {
101- o .onCompleted ();
101+ if (!o .isUnsubscribed ()) {
102+ o .onCompleted ();
103+ }
102104 return ;
103105 }
104106 if (REQUESTED_UPDATER .addAndGet (this , -r ) == 0 ) {
Original file line number Diff line number Diff line change @@ -186,7 +186,8 @@ private void handleNewSource(Observable<? extends T> t) {
186186 InnerSubscriber <T > i = new InnerSubscriber <T >(this , producerIfNeeded );
187187 i .sindex = childrenSubscribers .add (i );
188188 t .unsafeSubscribe (i );
189- request (1 );
189+ if (!isUnsubscribed ())
190+ request (1 );
190191 }
191192
192193 private void handleScalarSynchronousObservable (ScalarSynchronousObservable <? extends T > t ) {
You can’t perform that action at this time.
0 commit comments