From 948d4cbde662256530e4b7e02e9bf148dedbc255 Mon Sep 17 00:00:00 2001 From: Matthias Maier Date: Mon, 4 May 2015 10:15:56 +0200 Subject: [PATCH] Bugfix: Correctly set up object in move constructor --- include/deal.II/lac/trilinos_parallel_block_vector.h | 1 + source/lac/trilinos_vector.cc | 3 +++ 2 files changed, 4 insertions(+) diff --git a/include/deal.II/lac/trilinos_parallel_block_vector.h b/include/deal.II/lac/trilinos_parallel_block_vector.h index 79b5ce176c..9539aef1db 100644 --- a/include/deal.II/lac/trilinos_parallel_block_vector.h +++ b/include/deal.II/lac/trilinos_parallel_block_vector.h @@ -404,6 +404,7 @@ namespace TrilinosWrappers inline BlockVector::BlockVector (BlockVector &&v) { + reinit (0); swap(v); } #endif diff --git a/source/lac/trilinos_vector.cc b/source/lac/trilinos_vector.cc index 26584f5e7e..5c34386a87 100644 --- a/source/lac/trilinos_vector.cc +++ b/source/lac/trilinos_vector.cc @@ -128,6 +128,9 @@ namespace TrilinosWrappers #ifdef DEAL_II_WITH_CXX11 Vector::Vector (Vector &&v) { + last_action = Zero; + vector.reset(new Epetra_FEVector(Epetra_Map(0,0,0,Utilities::Trilinos::comm_self()))); + swap(v); } #endif -- 2.39.5