fix curve not ending on last control point