Fix bug in bt_cleanpage and bt_splitpage