]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Correct the implementation of DataOutBase::Patch::memory_consumption. 5003/head
authorWolfgang Bangerth <bangerth@colostate.edu>
Thu, 31 Aug 2017 23:23:09 +0000 (17:23 -0600)
committerWolfgang Bangerth <bangerth@colostate.edu>
Thu, 31 Aug 2017 23:25:58 +0000 (17:25 -0600)
source/base/data_out_base.cc

index 6d9428adddd7d2cf2dd50379cd7896e881bdb88c..3168531d4fe403de609627c51e9e053a788adaec 100644 (file)
@@ -1607,9 +1607,14 @@ namespace DataOutBase
   std::size_t
   Patch<dim,spacedim>::memory_consumption () const
   {
-    return (sizeof(vertices) / sizeof(vertices[0]) *
+    return (sizeof(vertices)/sizeof(vertices[0]) *
             MemoryConsumption::memory_consumption(vertices[0])
             +
+            sizeof(neighbors)/sizeof(neighbors[0]) *
+            MemoryConsumption::memory_consumption(neighbors[0])
+            +
+            MemoryConsumption::memory_consumption(patch_index)
+            +
             MemoryConsumption::memory_consumption(n_subdivisions)
             +
             MemoryConsumption::memory_consumption(data)

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.