merge buffers