[mapguide-commits] r9360 - trunk/MgDev/Common/CoordinateSystem

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Tue Mar 6 06:00:25 PST 2018


Author: jng
Date: 2018-03-06 06:00:24 -0800 (Tue, 06 Mar 2018)
New Revision: 9360

Modified:
   trunk/MgDev/Common/CoordinateSystem/CoordSysMathComparator.cpp
Log:
Disable invalid assertion in CCoordinateSystemMathComparator::SameCoordinateSystem

Fixes #1827

Modified: trunk/MgDev/Common/CoordinateSystem/CoordSysMathComparator.cpp
===================================================================
--- trunk/MgDev/Common/CoordinateSystem/CoordSysMathComparator.cpp	2018-03-06 12:45:29 UTC (rev 9359)
+++ trunk/MgDev/Common/CoordinateSystem/CoordSysMathComparator.cpp	2018-03-06 14:00:24 UTC (rev 9360)
@@ -484,8 +484,13 @@
     // Map scale is rarely (if ever) used and us usally set to unity.
     if (!FloatEqual(def1.map_scl, def2.map_scl, kdEpsilonScale)) return false;
 
+    //Disabling assertion below (per: https://trac.osgeo.org/mapguide/ticket/1827):
+    //
+    // CSMAP generates the unit_scl value from the ellipsoid / datum when an ellipsoid / datum is set via [CoordSys::SetEllipsoid / SetDatum] methods.
+    // When then comparing the resulting coordinate system objects, the ellipsoids are considered the same (by the math comparator) but the unit scales are not; at least not by the assert
+    //
     //If the units match, the unit scale matches.
-    assert(FloatEqual(def1.unit_scl, def2.unit_scl, kdEpsilonScale));
+    //assert(FloatEqual(def1.unit_scl, def2.unit_scl, kdEpsilonScale));
 
     //Note:  We deliberately do not make any assertion
     //about def1.scale being equal to def2.scale.  They



More information about the mapguide-commits mailing list