Flush the output stream after all bytes have been read.
[xudocci.git] / src / main / java / net / pterodactylus / irc / DccReceiver.java
index 5c5eac4..a6a55eb 100644 (file)
@@ -159,6 +159,7 @@ public class DccReceiver extends AbstractExecutionThreadService {
                                outputStream.write(buffer, 0, r);
                                progress += r;
                        }
+                       outputStream.flush();
                } catch (IOException ioe1) {
                        logger.log(Level.WARNING, "I/O error while receiving DCC!", ioe1);
                } finally {