From: Martin Kronbichler Date: Tue, 28 Jul 2009 15:18:39 +0000 (+0000) Subject: One more change to make things with the extra Trilinos vector really work (hopefully). X-Git-Tag: v8.0.0~7438 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2e94c9a2ad5c4254e4d0800c46ef7a9789183452;p=dealii.git One more change to make things with the extra Trilinos vector really work (hopefully). git-svn-id: https://svn.dealii.org/trunk@19127 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/lac/include/lac/constraint_matrix.h b/deal.II/lac/include/lac/constraint_matrix.h index c6b8a39c7c..ad67cbc78f 100644 --- a/deal.II/lac/include/lac/constraint_matrix.h +++ b/deal.II/lac/include/lac/constraint_matrix.h @@ -328,6 +328,11 @@ class ConstraintMatrix : public Subscriptor */ ConstraintMatrix (); + /** + * Copy constructor + */ + ConstraintMatrix (const ConstraintMatrix &constraint_matrix); + /** * @name Adding constraints * @{ @@ -1521,7 +1526,7 @@ class ConstraintMatrix : public Subscriptor * This vector is used to import data * within the distribute function. */ - mutable std_cxx1x::shared_ptr vec_distribute; + mutable std::auto_ptr vec_distribute; #endif }; @@ -1537,6 +1542,19 @@ ConstraintMatrix::ConstraintMatrix () {} + +inline +ConstraintMatrix::ConstraintMatrix (const ConstraintMatrix &constraint_matrix) + : + lines (constraint_matrix.lines), + constraint_line_exists (constraint_matrix.constraint_line_exists), + sorted (constraint_matrix.sorted) +#ifdef DEAL_II_USE_TRILINOS + ,vec_distribute () +#endif +{} + + inline void ConstraintMatrix::add_line (const unsigned int line) diff --git a/deal.II/lac/source/constraint_matrix.cc b/deal.II/lac/source/constraint_matrix.cc index 0624e8cfdf..5bd0c374fe 100644 --- a/deal.II/lac/source/constraint_matrix.cc +++ b/deal.II/lac/source/constraint_matrix.cc @@ -1917,7 +1917,7 @@ ConstraintMatrix::distribute (TrilinosWrappers::MPI::Vector &vec) const my_indices.resize(index2); Epetra_Map map_exchange = Epetra_Map(-1,index2,(int*)&my_indices[0],0,vec.trilinos_vector().Comm()); - vec_distribute = std_cxx1x::shared_ptr + vec_distribute = std::auto_ptr (new TrilinosWrappers::MPI::Vector(map_exchange)); } // here we import the data