projects
/
sonitus.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Log exactly which part of the connection has died.
[sonitus.git]
/
src
/
main
/
java
/
net
/
pterodactylus
/
sonitus
/
data
/
Connection.java
diff --git
a/src/main/java/net/pterodactylus/sonitus/data/Connection.java
b/src/main/java/net/pterodactylus/sonitus/data/Connection.java
index
8ea1a55
..
169bfa5
100644
(file)
--- a/
src/main/java/net/pterodactylus/sonitus/data/Connection.java
+++ b/
src/main/java/net/pterodactylus/sonitus/data/Connection.java
@@
-56,8
+56,14
@@
public abstract class Connection implements Runnable {
@Override
public void run() {
while (true) {
@Override
public void run() {
while (true) {
+ byte[] buffer = null;
+ try {
+ buffer = source.get(bufferSize());
+ } catch (IOException ioe1) {
+ logger.log(Level.WARNING, "Source died!", ioe1);
+ break;
+ }
try {
try {
- byte[] buffer = source.get(bufferSize());
feed(buffer);
} catch (IOException ioe1) {
logger.log(Level.WARNING, "Sink died!", ioe1);
feed(buffer);
} catch (IOException ioe1) {
logger.log(Level.WARNING, "Sink died!", ioe1);