diff --git a/src/mmg3d/colver_3d.c b/src/mmg3d/colver_3d.c index 5400b4a72..3c2b34dfa 100644 --- a/src/mmg3d/colver_3d.c +++ b/src/mmg3d/colver_3d.c @@ -393,8 +393,8 @@ int MMG3D_get_shellEdgeTag_oneDir(MMG5_pMesh mesh,MMG5_int start, MMG5_int na, if ( pt->xt ) { pxt = &mesh->xtetra[pt->xt]; *ref = pxt->edg[i]; - if ( pxt->tag[i] & MG_BDY ) { - *tag |= pxt->tag[i]; + if ((pxt->ftag[MMG5_ifar[i][0]] & MG_BDY) || (pxt->ftag[MMG5_ifar[i][1]] & MG_BDY)) { + *tag |= (pxt->tag[i] | MG_BDY); *filled = 1; return adj; } @@ -444,8 +444,8 @@ int MMG3D_get_shellEdgeTag(MMG5_pMesh mesh,MMG5_int start, int8_t ia,int16_t *t if ( pt->xt ) { pxt = &mesh->xtetra[pt->xt]; - if ( pxt->tag[ia] & MG_BDY ) { - *tag |= pxt->tag[ia]; + if ((pxt->ftag[MMG5_ifar[ia][0]] & MG_BDY) || (pxt->ftag[MMG5_ifar[ia][1]] & MG_BDY)) { + *tag |= (pxt->tag[ia] | MG_BDY); *ref = pxt->edg[ia]; return 1; }