summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSergio Giro <sgiro@google.com>2015-06-16 17:43:07 +0100
committerSergio Giro <sgiro@google.com>2015-06-17 10:48:01 +0100
commitca6b6ed5a9b4f16a2ecadf8e1d57ca238e387476 (patch)
tree75614635a9873098d81443bc51ef659bda0be108
parent50ed29db9f963733ab117f8ae04291a6eab09dbc (diff)
downloadlibcore-ca6b6ed5a9b4f16a2ecadf8e1d57ca238e387476.tar.gz
libcore-ca6b6ed5a9b4f16a2ecadf8e1d57ca238e387476.tar.bz2
libcore-ca6b6ed5a9b4f16a2ecadf8e1d57ca238e387476.zip
libcore: removed unnecessary code in SSLSocketTest
Was possibly causing a race condition (see b/21776011), for instance, in case readFirstReceivedChunkFuture was still executing IoUtils#closeQuietly while the thread was cancelled. Bug: 21776011 (cherry picked from commit c22dd77f727262ed8105b8b638aeb817997914fd) Change-Id: Ibb20a98102d5bdc9ac3eaa0b875801ab218356f1
-rw-r--r--luni/src/test/java/libcore/javax/net/ssl/SSLSocketTest.java7
1 files changed, 0 insertions, 7 deletions
diff --git a/luni/src/test/java/libcore/javax/net/ssl/SSLSocketTest.java b/luni/src/test/java/libcore/javax/net/ssl/SSLSocketTest.java
index 7e0505421..bf2d0f895 100644
--- a/luni/src/test/java/libcore/javax/net/ssl/SSLSocketTest.java
+++ b/luni/src/test/java/libcore/javax/net/ssl/SSLSocketTest.java
@@ -1709,13 +1709,6 @@ public class SSLSocketTest extends TestCase {
return null;
} finally {
IoUtils.closeQuietly(client);
-
- // Cancel the reading task. If this task succeeded, then the reading task
- // is done and this will have no effect. If this task failed prematurely,
- // then the reading task might get unblocked (we're interrupting the thread
- // it's running on), will fail early, and we'll thus save some time in this
- // test.
- readFirstReceivedChunkFuture.cancel(true);
}
}
});