allow buffers to be passed