Less hacky solution to kGap problems and CheckBuffer() overuse