Fix segfault in the bNeedToCheckWholeTable case