When measuring the deviation of the end of the added edge from the resulting edge take the point on the curve, not from the vertex. Test cases for the issue.