aboutsummaryrefslogtreecommitdiff
path: root/org.jacoco.examples
diff options
context:
space:
mode:
authorMarc R. Hoffmann <hoffmann@mountainminds.com>2017-05-25 00:14:30 +0200
committerEvgeny Mandrikov <Godin@users.noreply.github.com>2017-05-25 00:14:30 +0200
commit10f3ff0dd010d647625ef5937f301126250267d0 (patch)
tree1014cc0f8124adc5b46c78603f8f4367e6d80939 /org.jacoco.examples
parent938b0b4e0226f64ce7c5fac66a94fdb5d18f3f67 (diff)
downloadjacoco-10f3ff0dd010d647625ef5937f301126250267d0.tar.gz
ExecDumpClient should report error when no data is retrieved (#538)
Diffstat (limited to 'org.jacoco.examples')
-rw-r--r--org.jacoco.examples/src/org/jacoco/examples/ExecutionDataClient.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/org.jacoco.examples/src/org/jacoco/examples/ExecutionDataClient.java b/org.jacoco.examples/src/org/jacoco/examples/ExecutionDataClient.java
index 48f794c4..d190a479 100644
--- a/org.jacoco.examples/src/org/jacoco/examples/ExecutionDataClient.java
+++ b/org.jacoco.examples/src/org/jacoco/examples/ExecutionDataClient.java
@@ -55,7 +55,9 @@ public final class ExecutionDataClient {
// Send a dump command and read the response:
writer.visitDumpCommand(true, false);
- reader.read();
+ if (!reader.read()) {
+ throw new IOException("Socket closed unexpectedly.");
+ }
socket.close();
localFile.close();