Commits

Nico Schlömer committed ebe77ec

undo one range-based loop

  • Participants
  • Parent commits b24151f
  • Branches coverity-fixes-2

Comments (0)

Files changed (1)

File dolfin/refinement/ParallelRefinement.cpp

   // sent off-process.  Add offset to map, and collect up any shared
   // new vertices that need to send the new index off-process
   std::vector<std::vector<std::size_t> > values_to_send(num_processes);
-  for (auto local_edge: local_edge_to_new_vertex)
+  for (auto local_edge = local_edge_to_new_vertex.begin();
+       local_edge != local_edge_to_new_vertex.end();
+       ++local_edge)
   {
     // Add global_offset to map, to get new global index of new vertices
-    local_edge.second += global_offset;
+    local_edge->second += global_offset;
 
-    const std::size_t local_i = local_edge.first;
+    const std::size_t local_i = local_edge->first;
     //shared, but locally owned : remote owned are not in list.
     if (shared_edges.count(local_i) != 0)
     {
         const std::size_t remote_proc_num = remote_process_edge.first;
         // send mapping from remote local edge index to new global vertex index
         values_to_send[remote_proc_num].push_back(remote_process_edge.second);
-        values_to_send[remote_proc_num].push_back(local_edge.second);
+        values_to_send[remote_proc_num].push_back(local_edge->second);
       }
     }
   }