fix the buffer  clearing