Fix bug in sp pt finding