Repaired memory leak in OutputStream data allocation.
Now flushing after every cycle.