Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1575)

Unified Diff: runtime/bin/socket_patch.dart

Issue 14103010: Change hasSubscribers to hasListener. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed comments. Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/scheduled_test/lib/src/mock_clock.dart ('k') | sdk/lib/async/stream.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/socket_patch.dart
diff --git a/runtime/bin/socket_patch.dart b/runtime/bin/socket_patch.dart
index fae7902b08ecdd35c66088373c94ec43ce3a1b1b..81e8ab379728d001376dd6c6a8b4179a6f799f6d 100644
--- a/runtime/bin/socket_patch.dart
+++ b/runtime/bin/socket_patch.dart
@@ -471,7 +471,7 @@ class _RawServerSocket extends Stream<RawSocket>
}
void _onSubscriptionStateChange() {
- if (_controller.hasSubscribers) {
+ if (_controller.hasListener) {
_resume();
} else {
close();
@@ -598,7 +598,7 @@ class _RawSocket extends Stream<RawSocketEvent>
}
void _onSubscriptionStateChange() {
- if (_controller.hasSubscribers) {
+ if (_controller.hasListener) {
_resume();
} else {
close();
@@ -867,7 +867,7 @@ class _Socket extends Stream<List<int>> implements Socket {
}
void _onSubscriptionStateChange() {
- if (_controller.hasSubscribers) {
+ if (_controller.hasListener) {
_ensureRawSocketSubscription();
// Enable read events for providing data to subscription.
if (_raw != null) {
« no previous file with comments | « pkg/scheduled_test/lib/src/mock_clock.dart ('k') | sdk/lib/async/stream.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698