added buffer feature