Rename exception variable.
[sonitus.git] / src / main / java / net / pterodactylus / sonitus / data / Connection.java
index 762ba02..9377579 100644 (file)
@@ -54,10 +54,15 @@ public abstract class Connection implements Runnable {
                        try {
                                byte[] buffer = source.get(bufferSize());
                                feed(buffer);
-                       } catch (IOException e) {
-                               return;
+                       } catch (IOException ioe1) {
+                               break;
                        }
                }
+               try {
+                       finish();
+               } catch (IOException ioe1) {
+                       /* well, what can we do? nothing. */
+               }
        }
 
        //