Why does everything work except the part with the buffers