Pointer out of range fix
Another index fix
Fix pointer issue