fixed the buffer sizes