diff --git a/include/cantera/oneD/IonFlow.h b/include/cantera/oneD/IonFlow.h index 85319fdb2..7ee686056 100644 --- a/include/cantera/oneD/IonFlow.h +++ b/include/cantera/oneD/IonFlow.h @@ -82,7 +82,7 @@ protected: bool m_import_electron_transport; //! electrical properties - vector_int m_speciesCharge; + vector_fp m_speciesCharge; //! index of species with charges std::vector m_kCharge; @@ -98,7 +98,7 @@ protected: vector_fp m_mobility; //! solving stage - int m_stage; + size_t m_stage; //! index of electron size_t m_kElectron; diff --git a/include/cantera/transport/IonGasTransport.h b/include/cantera/transport/IonGasTransport.h index 54513758a..19d711620 100644 --- a/include/cantera/transport/IonGasTransport.h +++ b/include/cantera/transport/IonGasTransport.h @@ -81,7 +81,7 @@ protected: double omega11_n64(const double tstar, const double gamma); //! electrical properties - vector_int m_speciesCharge; + vector_fp m_speciesCharge; //! index of ions (exclude electron.) std::vector m_kIon; diff --git a/src/base/stringUtils.cpp b/src/base/stringUtils.cpp index 4816b435b..6d4bd166c 100644 --- a/src/base/stringUtils.cpp +++ b/src/base/stringUtils.cpp @@ -84,7 +84,7 @@ compositionMap parseCompString(const std::string& ss, double value; try { value = fpValueCheck(ss.substr(valstart, stop-valstart)); - } catch (CanteraError& err) { + } catch (CanteraError&) { // If we have a key containing a colon, we expect this to fail. In // this case, take the current substring as part of the key and look // to the right of the next colon for the corresponding value. diff --git a/src/clib/ctreactor.cpp b/src/clib/ctreactor.cpp index de49a4336..7938174e1 100644 --- a/src/clib/ctreactor.cpp +++ b/src/clib/ctreactor.cpp @@ -169,7 +169,7 @@ extern "C" { try { // @todo This should not fail silently if (ReactorCabinet::item(i).type() >= ReactorType) { - ReactorCabinet::get(i).setChemistry(cflag); + ReactorCabinet::get(i).setChemistry(cflag != 0); } return 0; } catch (...) { diff --git a/src/numerics/IDA_Solver.cpp b/src/numerics/IDA_Solver.cpp index 5cd54dea6..a5b88101e 100644 --- a/src/numerics/IDA_Solver.cpp +++ b/src/numerics/IDA_Solver.cpp @@ -122,7 +122,7 @@ extern "C" { } else if (SUNMatGetID(Jac) == SUNMATRIX_BAND) { cols = SM_COLS_B(Jac); } else { - throw Cantera::CanteraError("ida_jacobian", "Unknown SUNMatrix type"); + return 1; // Unknown SUNMatrix type } f->evalJacobianDP(t, delta_t, c_j, NV_DATA_S(y), NV_DATA_S(yp), cols, NV_DATA_S(r)); diff --git a/src/zeroD/Reactor.cpp b/src/zeroD/Reactor.cpp index abb1301b4..50d3b005c 100644 --- a/src/zeroD/Reactor.cpp +++ b/src/zeroD/Reactor.cpp @@ -143,7 +143,7 @@ void Reactor::updateState(doublereal* y) try { TT = bmt::bracket_and_solve_root( u_err, T, 1.2, true, bmt::eps_tolerance(48), maxiter); - } catch (std::exception& err) { + } catch (std::exception&) { // Try full-range bisection if bracketing fails (e.g. near // temperature limits for the phase's equation of state) try {