Fix #6 by removing break from write with buffer function.