diff options
Diffstat (limited to 'source/luametatex/source/mp/mpc/mp.c')
-rw-r--r-- | source/luametatex/source/mp/mpc/mp.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/source/luametatex/source/mp/mpc/mp.c b/source/luametatex/source/mp/mpc/mp.c index d171e07a6..2d0320868 100644 --- a/source/luametatex/source/mp/mpc/mp.c +++ b/source/luametatex/source/mp/mpc/mp.c @@ -9028,11 +9028,21 @@ static mp_knot mp_path_intersection(MP mp, mp_knot h, mp_knot hh, int path, mp_k number_add(nn, unity_t); ll = pp; pp = mp_next_knot(pp); +if (pp != hh && mp_knotstate(pp) == mp_end_knot) { + number_add(nn, unity_t); + ll = pp; + pp = mp_next_knot(pp); +} } while (pp != hh); } number_add(n, unity_t); l = p; p = mp_next_knot(p); +if (p != hh && mp_knotstate(p) == mp_end_knot) { + number_add(n, unity_t); + l = p; + p = mp_next_knot(p); +} } while (p != h); mp->tol_step = mp->tol_step + 3; if (done) { |