From c0ef6a2fbc630afe13e4e29ff996973439000722 Mon Sep 17 00:00:00 2001 From: bangerth Date: Wed, 19 Feb 2014 19:44:05 +0000 Subject: [PATCH] Patch by Mayank Sabharwal: Fix an indexing error in GridIn::read_vtk(). git-svn-id: https://svn.dealii.org/trunk@32517 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/doc/news/changes.h | 9 +++++++-- deal.II/source/grid/grid_in.cc | 6 +++--- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/deal.II/doc/news/changes.h b/deal.II/doc/news/changes.h index beb94ec9ee..dcdfd4082a 100644 --- a/deal.II/doc/news/changes.h +++ b/deal.II/doc/news/changes.h @@ -135,8 +135,13 @@ inconvenience this causes.

Specific improvements

    -
  1. New: There is a new namespace TimeStepping for the algorithms that do time - integrations. In this new namespace, several Runge-Kutta methods have been +
  2. Fixed: There was an indexing error in GridIn::read_vtk() that triggered + for some input files. This is now fixed. +
    + (Mayank Sabharwal, 2014/02/19) + +
  3. New: There is a new namespace TimeStepping for the algorithms that do time + integrations. In this new namespace, several Runge-Kutta methods have been implemented: explicit methods, implicit methods, and embedded explicit methods.
    (Damien Lebrun-Grandie, Bruno Turcksin, 2014/02/17) diff --git a/deal.II/source/grid/grid_in.cc b/deal.II/source/grid/grid_in.cc index c3072c1218..be09afad43 100644 --- a/deal.II/source/grid/grid_in.cc +++ b/deal.II/source/grid/grid_in.cc @@ -1,7 +1,7 @@ // --------------------------------------------------------------------- // $Id$ // -// Copyright (C) 1999 - 2013 by the deal.II authors +// Copyright (C) 1999 - 2014 by the deal.II authors // // This file is part of the deal.II library. // @@ -175,7 +175,7 @@ void GridIn::read_vtk(std::istream &in) { subcelldata.boundary_quads.back().vertices[j] = vertex_indices[subcelldata.boundary_quads.back().vertices[j]]; } - quad_indices[count] = count + 1; + quad_indices[no_quads] = no_quads + 1; no_quads++; } @@ -224,7 +224,7 @@ void GridIn::read_vtk(std::istream &in) { subcelldata.boundary_lines.back().vertices[j] = vertex_indices[subcelldata.boundary_lines.back().vertices[j]]; } - line_indices[count] = count + 1; + line_indices[no_lines] = no_lines + 1; no_lines++; } -- 2.39.5