]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
fix sneaky bug in MT
authorhartmann <hartmann@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 29 May 2000 16:04:19 +0000 (16:04 +0000)
committerhartmann <hartmann@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 29 May 2000 16:04:19 +0000 (16:04 +0000)
git-svn-id: https://svn.dealii.org/branches/Branch-3-0@2973 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/numerics/data_out.cc

index 388a06245322d2dfdb2b7f232b2be9d9d079104f..067d7e510ba87af588445ab1c0690c4663b6b661 100644 (file)
@@ -198,9 +198,13 @@ void DataOut<dim>::build_some_patches (Data data)
   DoFHandler<dim>::cell_iterator cell=first_cell();
 
                                   // get first cell in this thread
-  for (unsigned int i=0;i<data.this_thread;++i,++patch,++cell_number,
-                cell=next_cell(cell));
-  
+  for (unsigned int i=0; (i<data.this_thread)&&(cell != dofs->end()); ++i)
+    {
+      ++patch;
+      ++cell_number;
+      cell=next_cell(cell);
+    }
+
                                   // now loop over all cells and
                                   // actually create the patches
   for (;cell != dofs->end();)
@@ -247,9 +251,13 @@ void DataOut<dim>::build_some_patches (Data data)
            };
        };
                                       // next cell (patch) in this thread
-      for (unsigned int i=0;((i<data.n_threads)&&(cell != dofs->end()));
-          ++i,++patch,++cell_number,cell=next_cell(cell));
-      
+      for (unsigned int i=0;
+          (i<data.n_threads)&&(cell != dofs->end()); ++i)
+       {
+         ++patch;
+         ++cell_number;
+         cell=next_cell(cell);
+       }
     };
 }
 

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.