Fix buffer manager trash error