reset buffer for next read