tried to fix the buffer