From ccc3077efea5b0c59fa394c215c293e6715a9262 Mon Sep 17 00:00:00 2001 From: Giovanni Bussi Date: Tue, 8 Nov 2022 15:47:39 +0100 Subject: [PATCH] Small fixes associated to last commit Now that cppcheck can access header files for optional modules, a few more inconsistencies were spotted out. --- src/dimred/OutputPCAProjections.cpp | 2 +- src/sasa/sasa_HASEL.cpp | 1 + src/sasa/sasa_LCPO.cpp | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/dimred/OutputPCAProjections.cpp b/src/dimred/OutputPCAProjections.cpp index b702972e35..3d57309bee 100644 --- a/src/dimred/OutputPCAProjections.cpp +++ b/src/dimred/OutputPCAProjections.cpp @@ -94,7 +94,7 @@ void OutputPCAProjection::performAnalysis() { mypdb.setAtomPositions( (mypca->myref)->getReferencePositions() ); for(unsigned j=0; jgetArguments().size(); ++j) mypdb.setArgumentValue( (mypca->getArguments()[j])->getName(), (mypca->myref)->getReferenceArgument(j) ); // And output the first frame - afile.open( filename.c_str() ); afile.printf("REMARK TYPE=%s \n", mypca->mtype.c_str() ); + afile.open( filename ); afile.printf("REMARK TYPE=%s \n", mypca->mtype.c_str() ); if( plumed.getAtoms().usingNaturalUnits() ) mypdb.print( 1.0, mymoldat, afile, fmt ); else mypdb.print( atoms.getUnits().getLength()/0.1, mymoldat, afile, fmt ); // And now output the eigenvectors diff --git a/src/sasa/sasa_HASEL.cpp b/src/sasa/sasa_HASEL.cpp index d93c645e33..eac2c25d3c 100644 --- a/src/sasa/sasa_HASEL.cpp +++ b/src/sasa/sasa_HASEL.cpp @@ -137,6 +137,7 @@ class SASA_HASEL : public Colvar { unsigned nl_update; int firstStepFlag; double Ti; + // cppcheck-suppress duplInheritedMember std::vector atoms; vector < vector < std::string > > AtomResidueName; vector < vector < double > > SASAparam; diff --git a/src/sasa/sasa_LCPO.cpp b/src/sasa/sasa_LCPO.cpp index 6391164233..dc1d05c555 100755 --- a/src/sasa/sasa_LCPO.cpp +++ b/src/sasa/sasa_LCPO.cpp @@ -136,6 +136,7 @@ class SASA_LCPO : public Colvar { unsigned nl_update; int firstStepFlag; double Ti; + // cppcheck-suppress duplInheritedMember std::vector atoms; vector < vector < std::string > > AtomResidueName; vector < vector < double > > LCPOparam;