Flush the connection after handling packets
Flush the connection after handling packets

When we have only a few packets to be written after an epoc of read,
bufio will not write any packets back into pipe. For that reason, we
need to flush the buffer as soon as we process all messages.

soheilhy/beehive-netctrl,kandoo/beehive-netctrl