[MOAB-dev] r5456 - in MOAB/branches/Version4.5: . itaps/imesh

tautges at mcs.anl.gov tautges at mcs.anl.gov
Thu Mar 29 13:36:46 CDT 2012


Author: tautges
Date: 2012-03-29 13:36:46 -0500 (Thu, 29 Mar 2012)
New Revision: 5456

Modified:
   MOAB/branches/Version4.5/
   MOAB/branches/Version4.5/itaps/imesh/iMesh_MOAB.cpp
Log:
Backporting fix from v5452 from trunk to vers 4.5.




Property changes on: MOAB/branches/Version4.5
___________________________________________________________________
Modified: svn:mergeinfo
   - /MOAB/branches/Version4.0:4323-4497
/MOAB/branches/jk-direct-tag:4069-4327
   + /MOAB/branches/Version4.0:4323-4497
/MOAB/branches/jk-direct-tag:4069-4327
/MOAB/trunk:5452

Modified: MOAB/branches/Version4.5/itaps/imesh/iMesh_MOAB.cpp
===================================================================
--- MOAB/branches/Version4.5/itaps/imesh/iMesh_MOAB.cpp	2012-03-29 18:34:21 UTC (rev 5455)
+++ MOAB/branches/Version4.5/itaps/imesh/iMesh_MOAB.cpp	2012-03-29 18:36:46 UTC (rev 5456)
@@ -1957,7 +1957,7 @@
                      tag_values_allocated,
                      tag_values_size, err);
     *tag_values_allocated /= sizeof(int);
-    *tag_values_size /= sizeof(int);
+    if (tag_values_size != tag_values_allocated) *tag_values_size /= sizeof(int);
   }
 
   void iMesh_getDblArrData (iMesh_Instance instance,
@@ -1976,7 +1976,7 @@
                      tag_values,
                      tag_values_allocated, tag_values_size, err);
     *tag_values_allocated /= sizeof(double);
-    *tag_values_size /= sizeof(double);
+    if (tag_values_size != tag_values_allocated) *tag_values_size /= sizeof(double);
   }
 
   void iMesh_getEHArrData (iMesh_Instance instance,
@@ -1996,7 +1996,7 @@
                      tag_value_allocated,
                      tag_value_size, err);
     *tag_value_allocated /= sizeof(iBase_EntityHandle);
-    *tag_value_size /= sizeof(iBase_EntityHandle);
+    if (tag_value_size != tag_value_allocated) *tag_value_size /= sizeof(iBase_EntityHandle);
   }
 
   void iMesh_getESHArrData (iMesh_Instance instance,
@@ -2016,7 +2016,7 @@
                      tag_value_allocated,
                      tag_value_size, err);
     *tag_value_allocated /= sizeof(iBase_EntityHandle);
-    *tag_value_size /= sizeof(iBase_EntityHandle);
+    if (tag_value_size != tag_value_allocated) *tag_value_size /= sizeof(iBase_EntityHandle);
   }
 
   void iMesh_setArrData (iMesh_Instance instance,



More information about the moab-dev mailing list