added set buffer, but having trouble