diff --git a/Cantera/src/base/Array.h b/Cantera/src/base/Array.h index 22c508748..bde5f28c6 100644 --- a/Cantera/src/base/Array.h +++ b/Cantera/src/base/Array.h @@ -56,8 +56,11 @@ namespace Cantera { /** * Default constructor. Create an empty array. */ - Array2D() : m_nrows(0), m_ncols(0) { - m_data.clear(); + Array2D() : + m_data(0), + m_nrows(0), + m_ncols(0) + { } //! Constructor. @@ -70,7 +73,7 @@ namespace Cantera { * @param v Default fill value. The default is 0.0 */ Array2D(const int m, const int n, const doublereal v = 0.0) - : m_nrows(m), m_ncols(n) { + : m_data(0), m_nrows(m), m_ncols(n) { m_data.resize(n*m); std::fill(m_data.begin(), m_data.end(), v); } @@ -79,7 +82,11 @@ namespace Cantera { /*! * @param y Array2D to make the copy from */ - Array2D(const Array2D& y) { + Array2D(const Array2D& y) : + m_data(0), + m_nrows(0), + m_ncols(0) + { m_nrows = y.m_nrows; m_ncols = y.m_ncols; m_data.resize(m_nrows*m_ncols); diff --git a/Cantera/src/base/mdp_allo.cpp b/Cantera/src/base/mdp_allo.cpp index 1d9f90e3f..d650ed919 100644 --- a/Cantera/src/base/mdp_allo.cpp +++ b/Cantera/src/base/mdp_allo.cpp @@ -1458,7 +1458,7 @@ namespace mdp { * * mdp_copy_dbl_1: * - * Copies one Double vector into another double vector + * Copies one contiguous double vector into another double vector * * Input * -------------