diff --git a/include/cantera/base/utilities.h b/include/cantera/base/utilities.h index 47f263894..3490a8705 100644 --- a/include/cantera/base/utilities.h +++ b/include/cantera/base/utilities.h @@ -482,8 +482,7 @@ R poly3(D x, R* c) //! Templated deep copy of a std vector of pointers /*! * Performs a deep copy of a std vectors of pointers to an object. This template - * assumes that that the templated object has a functioning copy constructor. It - * also assumes that pointers are zero when they are not malloced. + * assumes that that the templated object has a functioning copy constructor. * * @param fromVec Vector of pointers to a templated class. This will be * deep-copied to the other vector diff --git a/include/cantera/equil/vcs_SpeciesProperties.h b/include/cantera/equil/vcs_SpeciesProperties.h index c10a0db13..d1487a412 100644 --- a/include/cantera/equil/vcs_SpeciesProperties.h +++ b/include/cantera/equil/vcs_SpeciesProperties.h @@ -49,7 +49,7 @@ public: //! Representative value of the mole fraction of this species in a phase. //! This value is used for convergence issues and for calculation of - //! numerical derivs + //! numerical derivatives double ReferenceMoleFraction; vcs_SpeciesProperties(size_t indexPhase, size_t indexSpeciesPhase, diff --git a/include/cantera/equil/vcs_VolPhase.h b/include/cantera/equil/vcs_VolPhase.h index 21840dc77..371475b4e 100644 --- a/include/cantera/equil/vcs_VolPhase.h +++ b/include/cantera/equil/vcs_VolPhase.h @@ -14,9 +14,9 @@ #include "cantera/equil/vcs_SpeciesProperties.h" #include "cantera/base/Array.h" -// Forward reference for ThermoPhase object within the Cantera namespace namespace Cantera { + class ThermoPhase; //! Models for the standard state volume of each species diff --git a/include/cantera/equil/vcs_prob.h b/include/cantera/equil/vcs_prob.h index cd19c98cd..1e4f4c651 100644 --- a/include/cantera/equil/vcs_prob.h +++ b/include/cantera/equil/vcs_prob.h @@ -31,20 +31,20 @@ public: //! Total number of species in the problems size_t nspecies; - //! Species number used to malloc data structures + //! Species number used to size data structures size_t NSPECIES0; //! Number of element constraints in the equilibrium problem size_t ne; - //! Number of element constraints used to malloc data structures + //! Number of element constraints used to size data structures //! involving elements size_t NE0; //! Number of phases in the problem size_t NPhase; - //! Number of phases used to malloc data structures + //! Number of phases used to size data structures size_t NPHASE0; //! Vector of chemical potentials of the species. This is a calculated diff --git a/include/cantera/equil/vcs_solve.h b/include/cantera/equil/vcs_solve.h index e967c1206..73e368d62 100644 --- a/include/cantera/equil/vcs_solve.h +++ b/include/cantera/equil/vcs_solve.h @@ -1374,10 +1374,10 @@ private: vector_fp m_wx; public: - //! value of the number of species used to malloc data structures + //! value of the number of species used to size data structures size_t NSPECIES0; - //! value of the number of phases used to malloc data structures + //! value of the number of phases used to size data structures size_t NPHASE0; //! Total number of species in the problems diff --git a/include/cantera/kinetics/InterfaceKinetics.h b/include/cantera/kinetics/InterfaceKinetics.h index bfecbaf10..6291b74d1 100644 --- a/include/cantera/kinetics/InterfaceKinetics.h +++ b/include/cantera/kinetics/InterfaceKinetics.h @@ -510,10 +510,10 @@ protected: */ vector_fp m_beta; - //! Vector of reaction indexes specifying the id of the current transfer + //! Vector of reaction indexes specifying the id of the charge transfer //! reactions in the mechanism /*! - * Vector of reaction indices which involve current transfers. This provides + * Vector of reaction indices which involve charge transfers. This provides * an index into the m_beta and m_ctrxn_BVform array. * * irxn = m_ctrxn[i] diff --git a/include/cantera/kinetics/importKinetics.h b/include/cantera/kinetics/importKinetics.h index 229c871d8..3bad662c8 100644 --- a/include/cantera/kinetics/importKinetics.h +++ b/include/cantera/kinetics/importKinetics.h @@ -81,7 +81,7 @@ bool importKinetics(const XML_Node& phase, std::vector th, /*! * In a single call, this routine initializes a ThermoPhase object and a * homogeneous kinetics object for a phase. It returns the fully initialized - * ThermoPhase object ptr and kinetics ptr. + * ThermoPhase object pointer and kinetics pointer. * * @param root pointer to the XML tree which will be searched to find the * XML phase element. diff --git a/include/cantera/numerics/Func1.h b/include/cantera/numerics/Func1.h index 49aa7f322..8db78aa67 100644 --- a/include/cantera/numerics/Func1.h +++ b/include/cantera/numerics/Func1.h @@ -50,8 +50,8 @@ public: //! Duplicate the current function. /*! - * This duplicates the current function, returning a reference to the new - * malloced function. + * This duplicates the current function, returning a reference to the newly + * created function. */ virtual Func1& duplicate() const; @@ -65,7 +65,7 @@ public: //! Creates a derivative to the current function /*! - * This will malloc a derivative function and return a reference to the + * This will create a new derivative function and return a reference to the * function. */ virtual Func1& derivative() const; diff --git a/include/cantera/numerics/GeneralMatrix.h b/include/cantera/numerics/GeneralMatrix.h index ff0689230..10083904f 100644 --- a/include/cantera/numerics/GeneralMatrix.h +++ b/include/cantera/numerics/GeneralMatrix.h @@ -40,7 +40,7 @@ public: /*! * This function will duplicate the matrix given a generic GeneralMatrix * - * @returns a pointer to the malloced object + * @returns a pointer to the newly created object */ virtual GeneralMatrix* duplMyselfAsGeneralMatrix() const = 0; diff --git a/include/cantera/numerics/IDA_Solver.h b/include/cantera/numerics/IDA_Solver.h index 153daec92..9ce7eb4fe 100644 --- a/include/cantera/numerics/IDA_Solver.h +++ b/include/cantera/numerics/IDA_Solver.h @@ -36,7 +36,7 @@ public: }; -class ResidData; // forward reference +class ResidData; class IDA_Solver : public DAE_Solver { diff --git a/include/cantera/thermo/MetalSHEelectrons.h b/include/cantera/thermo/MetalSHEelectrons.h index a1f00e10e..b87ed3aa1 100644 --- a/include/cantera/thermo/MetalSHEelectrons.h +++ b/include/cantera/thermo/MetalSHEelectrons.h @@ -324,7 +324,7 @@ public: //! Make the default XML tree /*! - * @returns a malloced XML tree containing the default info. + * @returns a new XML tree containing the default info. */ static XML_Node* makeDefaultXMLTree(); diff --git a/include/cantera/thermo/PDSS.h b/include/cantera/thermo/PDSS.h index c23ba981a..da87bb87f 100644 --- a/include/cantera/thermo/PDSS.h +++ b/include/cantera/thermo/PDSS.h @@ -513,7 +513,6 @@ public: * object. It's needed for the duplicator capability * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param vpssmgr_ptr Pointer to the variable pressure standard state * calculator for this phase * @param spthermo_ptr Pointer to the optional SpeciesThermo object diff --git a/include/cantera/thermo/PDSS_ConstVol.h b/include/cantera/thermo/PDSS_ConstVol.h index c0684eefd..2d5d7723c 100644 --- a/include/cantera/thermo/PDSS_ConstVol.h +++ b/include/cantera/thermo/PDSS_ConstVol.h @@ -120,7 +120,6 @@ public: * does most of the work. * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param inputFile XML file containing the description of the phase * @param id Optional parameter identifying the name of the phase. @@ -141,7 +140,6 @@ public: * - initThermoXML(phaseNode) (cascade) * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param speciesNode XML Node containing the species information * @param phaseNode Reference to the phase Information for the phase diff --git a/include/cantera/thermo/PDSS_HKFT.h b/include/cantera/thermo/PDSS_HKFT.h index 95281c69a..b4da91280 100644 --- a/include/cantera/thermo/PDSS_HKFT.h +++ b/include/cantera/thermo/PDSS_HKFT.h @@ -136,7 +136,6 @@ public: * routine, which does most of the work. * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param inputFile XML file containing the description of the phase * @param id Optional parameter identifying the name of the @@ -157,7 +156,6 @@ public: * - initThermoXML(phaseNode) (cascade) * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param speciesNode XML Node containing the species information * @param phaseNode Reference to the phase Information for the phase diff --git a/include/cantera/thermo/PDSS_IdealGas.h b/include/cantera/thermo/PDSS_IdealGas.h index 690fbaed3..3673bf8dc 100644 --- a/include/cantera/thermo/PDSS_IdealGas.h +++ b/include/cantera/thermo/PDSS_IdealGas.h @@ -116,7 +116,6 @@ public: * routine, which does most of the work. * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param inputFile XML file containing the description of the phase * @param id Optional parameter identifying the name of the @@ -137,7 +136,6 @@ public: * - initThermoXML(phaseNode) (cascade) * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param phaseNode Reference to the phase Information for the phase * that owns this species. diff --git a/include/cantera/thermo/PDSS_IonsFromNeutral.h b/include/cantera/thermo/PDSS_IonsFromNeutral.h index 8b2af0f66..6a6963d34 100644 --- a/include/cantera/thermo/PDSS_IonsFromNeutral.h +++ b/include/cantera/thermo/PDSS_IonsFromNeutral.h @@ -132,7 +132,6 @@ public: * routine, which does most of the work. * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param inputFile XML file containing the description of the phase * @param id Optional parameter identifying the name of the @@ -153,7 +152,6 @@ public: * - initThermoXML(phaseNode) (cascade) * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param speciesNode Reference to the phase Information for the species * that this standard state refers to diff --git a/include/cantera/thermo/PDSS_SSVol.h b/include/cantera/thermo/PDSS_SSVol.h index 23165dd52..64c293490 100644 --- a/include/cantera/thermo/PDSS_SSVol.h +++ b/include/cantera/thermo/PDSS_SSVol.h @@ -257,7 +257,6 @@ private: * routine, which does most of the work. * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param inputFile XML file containing the description of the phase * @param id Optional parameter identifying the name of the @@ -278,7 +277,6 @@ private: * - initThermoXML(phaseNode) (cascade) * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param speciesNode XML Node containing the species information * @param phaseNode Reference to the phase Information for the phase diff --git a/include/cantera/thermo/PDSS_Water.h b/include/cantera/thermo/PDSS_Water.h index ebeeaa4b9..6d94d248d 100644 --- a/include/cantera/thermo/PDSS_Water.h +++ b/include/cantera/thermo/PDSS_Water.h @@ -214,7 +214,6 @@ public: * routine, which does most of the work. * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param inputFile XML file containing the description of the phase * @param id Optional parameter identifying the name of the @@ -236,7 +235,6 @@ public: * - initThermoXML(phaseNode) (cascade) * * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spindex Species index within the phase * @param phaseNode Reference to the phase Information for the phase * that owns this species. diff --git a/include/cantera/thermo/VPSSMgr.h b/include/cantera/thermo/VPSSMgr.h index 290a987fa..774c592b4 100644 --- a/include/cantera/thermo/VPSSMgr.h +++ b/include/cantera/thermo/VPSSMgr.h @@ -233,7 +233,6 @@ public: //! Constructor /*! * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spth Pointer to the optional SpeciesThermo object * that will handle the calculation of the reference * state thermodynamic coefficients. diff --git a/include/cantera/thermo/VPSSMgr_ConstVol.h b/include/cantera/thermo/VPSSMgr_ConstVol.h index b7604f813..f484d7583 100644 --- a/include/cantera/thermo/VPSSMgr_ConstVol.h +++ b/include/cantera/thermo/VPSSMgr_ConstVol.h @@ -31,12 +31,9 @@ class VPSSMgr_ConstVol : public VPSSMgr public: //! Constructor /*! - * @param vp_ptr Pointer to the owning VPStandardStateTP object - * for the phase. It's a requirement that this be - * already malloced. - * @param spth Pointer to the SpeciesThermo object for the - * phase. It's a requirement that this be already - * malloced. + * @param vp_ptr Pointer to the owning VPStandardStateTP object for the + * phase. + * @param spth Pointer to the SpeciesThermo object for the phase. */ VPSSMgr_ConstVol(VPStandardStateTP* vp_ptr, SpeciesThermo* spth); @@ -100,7 +97,7 @@ public: * @param k Species index within the phase * @param speciesNode Reference to the species node in the XML tree * @param phaseNode_ptr Pointer to the phase node in the XML tree - * @return Returns a pointer to the a newly malloced PDSS object + * @return Returns a pointer to the a newly created PDSS object * containing the parameterization */ virtual PDSS* createInstallPDSS(size_t k, const XML_Node& speciesNode, diff --git a/include/cantera/thermo/VPSSMgr_General.h b/include/cantera/thermo/VPSSMgr_General.h index 6606e2d8f..14e5f7932 100644 --- a/include/cantera/thermo/VPSSMgr_General.h +++ b/include/cantera/thermo/VPSSMgr_General.h @@ -36,9 +36,8 @@ public: //! Constructor /*! * @param vp_ptr Pointer to the owning VPStandardStateTP object for the - * phase. It's a requirement that this be already malloced. - * @param spth Pointer to the SpeciesThermo object for the phase. It's - * a requirement that this be already malloced. + * phase. + * @param spth Pointer to the SpeciesThermo object for the phase. */ VPSSMgr_General(VPStandardStateTP* vp_ptr, SpeciesThermo* spth); @@ -99,7 +98,7 @@ private: * instantiation has resulted in a SpeciesThermo object * being created and registered with the SpeciesThermo * manager class. - * @return Returns the pointer to a malloced PDSS object + * @return Returns the pointer to a newly created PDSS object */ PDSS* returnPDSS_ptr(size_t k, const XML_Node& speciesNode, const XML_Node* const phaseNode_ptr, bool& doST); @@ -119,7 +118,7 @@ public: * @param k Species number * @param speciesNode XML node for the standard state of the species * @param phaseNode_ptr pointer to the phase XML node - * @return Returns the pointer to the malloced PDSS object + * @return Returns the pointer to the newly created PDSS object */ virtual PDSS* createInstallPDSS(size_t k, const XML_Node& speciesNode, const XML_Node* const phaseNode_ptr); diff --git a/include/cantera/thermo/VPSSMgr_IdealGas.h b/include/cantera/thermo/VPSSMgr_IdealGas.h index 4d96ad58b..9ade2767d 100644 --- a/include/cantera/thermo/VPSSMgr_IdealGas.h +++ b/include/cantera/thermo/VPSSMgr_IdealGas.h @@ -64,7 +64,7 @@ public: * @param k Species index within the phase * @param speciesNode Reference to the species node in the XML tree * @param phaseNode_ptr Pointer to the phase node in the XML tree - * @return Returns a pointer to the a newly malloced PDSS object + * @return Returns a pointer to the a newly created PDSS object * containing the parameterization */ virtual PDSS* createInstallPDSS(size_t k, const XML_Node& speciesNode, diff --git a/include/cantera/thermo/VPSSMgr_Water_HKFT.h b/include/cantera/thermo/VPSSMgr_Water_HKFT.h index 05aaf6fe7..ba5d370be 100644 --- a/include/cantera/thermo/VPSSMgr_Water_HKFT.h +++ b/include/cantera/thermo/VPSSMgr_Water_HKFT.h @@ -29,7 +29,6 @@ public: //! Constructor /*! * @param vptp_ptr Pointer to the Variable pressure ThermoPhase object - * This object must have already been malloced. * @param spth Pointer to the optional SpeciesThermo object * that will handle the calculation of the reference * state thermodynamic coefficients. diff --git a/include/cantera/transport/TransportFactory.h b/include/cantera/transport/TransportFactory.h index 708763a2f..565723e49 100644 --- a/include/cantera/transport/TransportFactory.h +++ b/include/cantera/transport/TransportFactory.h @@ -251,7 +251,7 @@ private: * @param thermo ThermoPhase object associated with the phase, defaults * to null pointer * @param loglevel int containing the Loglevel, defaults to zero - * @param f ptr to the TransportFactory object if it's been malloced. + * @param f optional pointer to the TransportFactory object * @param ndim Number of dimensions for transport fluxes * * @ingroup tranprops @@ -263,7 +263,7 @@ Transport* newTransportMgr(const std::string& transportModel = "", thermo_t* the /*! * @param thermo ThermoPhase object associated with the phase * @param loglevel int containing the Loglevel, defaults to zero - * @param f ptr to the TransportFactory object if it's been allocated + * @param f pointer to the TransportFactory object if it's been allocated * @returns a transport manager for the phase * * @ingroup tranprops diff --git a/include/cantera/zeroD/FlowDevice.h b/include/cantera/zeroD/FlowDevice.h index f87aa7cab..983ddd5d1 100644 --- a/include/cantera/zeroD/FlowDevice.h +++ b/include/cantera/zeroD/FlowDevice.h @@ -12,7 +12,7 @@ namespace Cantera { class Func1; -class ReactorBase; // forward reference +class ReactorBase; const int MFC_Type = 1; const int PressureController_Type = 2; diff --git a/src/base/xml.cpp b/src/base/xml.cpp index 382cc4d36..cb35051dc 100644 --- a/src/base/xml.cpp +++ b/src/base/xml.cpp @@ -829,7 +829,7 @@ void XML_Node::copy(XML_Node* const node_dest) const for (size_t n = 0; n < m_children.size(); n++) { XML_Node* sc = m_children[n]; size_t ndc = node_dest->nChildren(); - // Here is where we do a malloc of the child node. + // Here is where we create the child node. node_dest->addChild(sc->name()); XML_Node* dc = vsc[ndc]; sc->copy(dc); diff --git a/src/equil/vcs_VolPhase.cpp b/src/equil/vcs_VolPhase.cpp index e2323d1fb..ea8e42129 100644 --- a/src/equil/vcs_VolPhase.cpp +++ b/src/equil/vcs_VolPhase.cpp @@ -1007,7 +1007,7 @@ size_t vcs_VolPhase::transferElementsFM(const ThermoPhase* const tPhase) ne++; } - // Assign and malloc structures + // Assign and resize structures elemResize(ne); if (ChargeNeutralityElement != npos) { diff --git a/src/equil/vcs_inest.cpp b/src/equil/vcs_inest.cpp index 819b8078e..f70e959f9 100644 --- a/src/equil/vcs_inest.cpp +++ b/src/equil/vcs_inest.cpp @@ -305,7 +305,7 @@ int VCS_SOLVE::vcs_inest_TP() } } - // Malloc temporary space for usage in this routine and in subroutines + // temporary space for usage in this routine and in subroutines vector_fp sm(m_numElemConstraints*m_numElemConstraints, 0.0); vector_fp ss(m_numElemConstraints, 0.0); vector_fp sa(m_numElemConstraints, 0.0); diff --git a/src/equil/vcs_solve.cpp b/src/equil/vcs_solve.cpp index ed2d50f6c..2b24af230 100644 --- a/src/equil/vcs_solve.cpp +++ b/src/equil/vcs_solve.cpp @@ -141,8 +141,7 @@ void VCS_SOLVE::vcs_initSizes(const size_t nspecies0, const size_t nelements, m_elType.resize(nelements, VCS_ELEM_TYPE_ABSPOS); m_elementActive.resize(nelements, 1); - // Malloc space for activity coefficients for all species. Set it equal to - // one. + // space for activity coefficients for all species. Set it equal to one. m_actConventionSpecies.resize(nspecies0, 0); m_phaseActConvention.resize(nphase0, 0); m_lnMnaughtSpecies.resize(nspecies0, 0.0); @@ -152,7 +151,7 @@ void VCS_SOLVE::vcs_initSizes(const size_t nspecies0, const size_t nelements, m_chargeSpecies.resize(nspecies0, 0.0); m_speciesThermoList.resize(nspecies0, (VCS_SPECIES_THERMO*)0); - // Malloc Phase Info + // Phase Info m_VolPhaseList.resize(nphase0, 0); for (size_t iph = 0; iph < nphase0; iph++) { m_VolPhaseList[iph] = new vcs_VolPhase(this); @@ -166,7 +165,7 @@ void VCS_SOLVE::vcs_initSizes(const size_t nspecies0, const size_t nelements, m_PMVolumeSpecies.resize(nspecies0, 0.0); - // Malloc space for counters kept within vcs + // counters kept within vcs m_VCount = new VCS_COUNTERS(); vcs_counters_init(1); @@ -383,7 +382,7 @@ int VCS_SOLVE::vcs_prob_specifyFully(const VCS_PROB* pub) // Copy over the charges m_chargeSpecies = pub->Charge; - // Malloc and Copy the VCS_SPECIES_THERMO structures + // Copy the VCS_SPECIES_THERMO structures for (size_t kspec = 0; kspec < nspecies; kspec++) { delete m_speciesThermoList[kspec]; VCS_SPECIES_THERMO* spf = pub->SpeciesThermo[kspec]; diff --git a/src/equil/vcs_solve_TP.cpp b/src/equil/vcs_solve_TP.cpp index e0e457562..ff13af2de 100644 --- a/src/equil/vcs_solve_TP.cpp +++ b/src/equil/vcs_solve_TP.cpp @@ -67,7 +67,7 @@ int VCS_SOLVE::vcs_solve_TP(int print_lvl, int printDetails, int maxit) vcs_counters_init(0); clockWC ticktock; - // Malloc temporary space for usage in this routine and in subroutines + // temporary space for usage in this routine and in subroutines m_sm.assign(m_numElemConstraints*m_numElemConstraints, 0.0); m_ss.assign(m_numElemConstraints, 0.0); m_sa.assign(m_numElemConstraints, 0.0); diff --git a/src/numerics/CVodesIntegrator.cpp b/src/numerics/CVodesIntegrator.cpp index 671f3f648..31e81fb03 100644 --- a/src/numerics/CVodesIntegrator.cpp +++ b/src/numerics/CVodesIntegrator.cpp @@ -238,7 +238,7 @@ void CVodesIntegrator::sensInit(double t0, FuncEval& func) CV_STAGGERED, CVSensRhsFn(0), m_yS); if (flag != CV_SUCCESS) { - throw CanteraError("CVodesIntegrator::sensInit", "Error in CVodeSensMalloc"); + throw CanteraError("CVodesIntegrator::sensInit", "Error in CVodeSensInit"); } vector_fp atol(m_np, m_abstolsens); flag = CVodeSensSStolerances(m_cvode_mem, m_reltolsens, atol.data()); diff --git a/src/numerics/IDA_Solver.cpp b/src/numerics/IDA_Solver.cpp index cd23d3216..25c546c46 100644 --- a/src/numerics/IDA_Solver.cpp +++ b/src/numerics/IDA_Solver.cpp @@ -344,9 +344,9 @@ void IDA_Solver::init(doublereal t0) "Memory allocation failed."); } else if (flag == IDA_ILL_INPUT) { throw CanteraError("IDA_Solver::init", - "Illegal value for IDAMalloc input argument."); + "Illegal value for IDAInit input argument."); } else { - throw CanteraError("IDA_Solver::init", "IDAMalloc failed."); + throw CanteraError("IDA_Solver::init", "IDAInit failed."); } } flag = IDASVtolerances(m_ida_mem, m_reltol, m_abstol); @@ -361,9 +361,9 @@ void IDA_Solver::init(doublereal t0) "Memory allocation failed."); } else if (flag == IDA_ILL_INPUT) { throw CanteraError("IDA_Solver::init", - "Illegal value for IDAMalloc input argument."); + "Illegal value for IDAInit input argument."); } else { - throw CanteraError("IDA_Solver::init", "IDAMalloc failed."); + throw CanteraError("IDA_Solver::init", "IDAInit failed."); } } flag = IDASStolerances(m_ida_mem, m_reltol, m_abstols); diff --git a/src/thermo/GeneralSpeciesThermo.cpp b/src/thermo/GeneralSpeciesThermo.cpp index e84161b78..132cf24d6 100644 --- a/src/thermo/GeneralSpeciesThermo.cpp +++ b/src/thermo/GeneralSpeciesThermo.cpp @@ -78,7 +78,7 @@ void GeneralSpeciesThermo::install_STIT(size_t index, { if (!stit_ptr) { throw CanteraError("GeneralSpeciesThermo::install_STIT", - "zero pointer"); + "null pointer"); } AssertThrowMsg(m_speciesLoc.find(index) == m_speciesLoc.end(), "GeneralSpeciesThermo::install_STIT", diff --git a/src/thermo/VPSSMgrFactory.h b/src/thermo/VPSSMgrFactory.h index 770bf1faa..49d2565bc 100644 --- a/src/thermo/VPSSMgrFactory.h +++ b/src/thermo/VPSSMgrFactory.h @@ -106,7 +106,7 @@ public: //! Create a new species property manager for a group of species /*! * This routine will look through species nodes. It will discover what each - * species needs for its species property managers. Then, it will malloc and + * species needs for its species property managers. Then, it will create and * return the proper species property manager to use. * * @param vp_ptr Variable pressure standard state ThermoPhase object @@ -115,7 +115,7 @@ public: * @param spDataNodeList Vector of XML_Nodes, each of which is a species XML * Node. There are m_kk of these. * - * @return Returns a pointer to a newly malloced species + * @return Returns a pointer to a newly created species * property manager object. */ virtual VPSSMgr* newVPSSMgr(VPStandardStateTP* vp_ptr, @@ -144,7 +144,7 @@ private: //! the type and (optionally) a pointer to the factory to use to create it. /*! * This utility program will look through species nodes. It will discover what - * each species needs for its species property managers. Then, it will malloc + * each species needs for its species property managers. Then, it will create * and return the proper species property manager to use. * * These functions allow using a different factory class that diff --git a/src/transport/LiquidTransport.cpp b/src/transport/LiquidTransport.cpp index ceac0f358..87643b9e1 100644 --- a/src/transport/LiquidTransport.cpp +++ b/src/transport/LiquidTransport.cpp @@ -247,8 +247,8 @@ bool LiquidTransport::initLiquid(LiquidTransportParams& tr) m_mw = m_thermo->molecularWeights(); // First populate mixing rules and indices (NOTE, we transfer pointers of - // malloced quantities. We zero out pointers so that we only have one copy - // of the malloced quantity) + // manually allocated quantities. We zero out pointers so that we only have + // one copy of the pointer) for (size_t k = 0; k < m_nsp; k++) { m_selfDiffMixModel[k] = tr.selfDiffusion[k]; tr.selfDiffusion[k] = 0;