revert all buffer.c commits