From: Anthony Geay Date: Mon, 5 Jan 2015 16:29:24 +0000 (+0100) Subject: A little miss in algorithm. Werror would detect this \! X-Git-Tag: V7_5_1rc1^2~1 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=3093c821d11eda2ceec8893cab1f175ab03ec674;p=tools%2Fmedcoupling.git A little miss in algorithm. Werror would detect this \! --- diff --git a/src/MEDCoupling/MEDCouplingUMesh.cxx b/src/MEDCoupling/MEDCouplingUMesh.cxx index 04636183b..4c6f32132 100644 --- a/src/MEDCoupling/MEDCouplingUMesh.cxx +++ b/src/MEDCoupling/MEDCouplingUMesh.cxx @@ -9520,13 +9520,18 @@ bool AreEdgeEqual(const double *coo2D, const INTERP_KERNEL::CellModel& typ1, con bool status0(conn1[0]==conn2[0] && conn1[1]==conn2[1]); if(!status0) return false; + const double *a(0),*bb(0),*be(0); if(typ1.isQuadratic()) { - const double *a(coo2D+2*conn1[2]),*bb(coo2D+2*conn2[0]),*be(coo2D+2*conn2[1]); - double b[2]; b[0]=(be[0]+bb[0])/2.; b[1]=(be[1]+bb[1])/2.; - double dist(sqrt((a[0]-b[0])*(a[0]-b[0])+(a[1]-b[1])*(a[1]-b[1]))); - return dist