+str #18486 Make sure that Source.subscriber's Subscriber throws if subscribed more than once

This commit is contained in:
Alexander Golubev 2015-09-24 22:25:06 -04:00
parent 5f2e50e416
commit 74dc99a656

View file

@ -379,11 +379,9 @@ private[stream] final class VirtualProcessor[T] extends Processor[T, T] {
case Completed tryOnComplete(s)
case Failed(ex) tryOnError(s, ex)
case Allowed // all good
}
} catch {
case ex @ canNotSubscribeTheSameSubscriberMultipleTimesException throw ex
case NonFatal(ex) sub.cancel()
case NonFatal(ex) if (isCancelled) throw ex else sub.cancel()
}
}
}