new update, change to write to buffer