more buffer fixes.