This avoids dereferencing (and then calculating the address of) an entry
one past the end.
const unsigned int local_pos_recv = vertices_recv_buffers[i][2*j];
const types::global_vertex_index global_id_recv = vertices_recv_buffers[i][2*j+1];
const std::string cellid_recv(&cellids_recv_buffers[i][max_cellid_size*j],
- &cellids_recv_buffers[i][max_cellid_size*(j+1)]);
+ &cellids_recv_buffers[i][max_cellid_size*j] + max_cellid_size);
bool found = false;
typename std::set<active_cell_iterator>::iterator
cell_set_it = missing_vert_cells.begin(),
cell_idx++;
}
- tria.create_triangulation(std::vector<Point<2>>(&vertices[0], &vertices[n_vert]),
- cells,
- SubCellData()); // no boundary information
+ tria.create_triangulation(vertices, cells, SubCellData()); // no boundary information
double eps = 1e-5 * x[0];
unsigned int label = 100;
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