diff --git a/FT/Espresso/Espresso/Calibration.hh b/FT/Espresso/Espresso/Calibration.hh index b87c668680b45f7a048c676ae68f559e3fd5233d..c576e7f1ccdbe02add1b39db82cebc10493b4241 100644 --- a/FT/Espresso/Espresso/Calibration.hh +++ b/FT/Espresso/Espresso/Calibration.hh @@ -216,7 +216,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) {} + void serialize(Archive&, const unsigned int) {} }; } diff --git a/FT/Espresso/Espresso/CalibrationFunction.hh b/FT/Espresso/Espresso/CalibrationFunction.hh index 123a2ad8a45eb90a3405068deb04659299c9935f..cbacfb85abf38cf7126413c36051990dfebd05a7 100644 --- a/FT/Espresso/Espresso/CalibrationFunction.hh +++ b/FT/Espresso/Espresso/CalibrationFunction.hh @@ -84,7 +84,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) {} + void serialize(Archive&, const unsigned int) {} }; } diff --git a/FT/Espresso/Espresso/GLMBSpline.hh b/FT/Espresso/Espresso/GLMBSpline.hh index a0c769829239a265c1a9a38dc7b9026be0d716d2..5368053467fb9c6b773e6d84a25c00a56067c43f 100644 --- a/FT/Espresso/Espresso/GLMBSpline.hh +++ b/FT/Espresso/Espresso/GLMBSpline.hh @@ -107,7 +107,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(GLMModel); //ar & boost::serialization::base_object<GLMModel>(*this); ar & BOOST_SERIALIZATION_NVP(nodes); @@ -131,13 +131,13 @@ namespace boost { namespace serialization { template<class Archive> - inline void save_construct_data(Archive& ar, const Espresso::GLMBSpline* v, const unsigned int version) { + inline void save_construct_data(Archive& ar, const Espresso::GLMBSpline* v, const unsigned int /* version */) { std::vector<double> nodes = v->GetNodes(); ar << BOOST_SERIALIZATION_NVP(nodes); } template<class Archive> - inline void load_construct_data(Archive& ar, Espresso::GLMBSpline* v, const unsigned int version) { + inline void load_construct_data(Archive& ar, Espresso::GLMBSpline* v, const unsigned int /* version */) { std::vector<double> nodes; ar >> BOOST_SERIALIZATION_NVP(nodes); ::new(v)Espresso::GLMBSpline(nodes); diff --git a/FT/Espresso/Espresso/GLMCalibration.hh b/FT/Espresso/Espresso/GLMCalibration.hh index cfe4447bb90b0299fdd56ba166066c42b54ec3bf..6ab2c9e32f8155a61eb8d52b1c6853a90931e5ff 100644 --- a/FT/Espresso/Espresso/GLMCalibration.hh +++ b/FT/Espresso/Espresso/GLMCalibration.hh @@ -140,7 +140,7 @@ namespace Espresso friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(TypicalCalibration); //ar & boost::serialization::base_object<TypicalCalibration>(*this); ar & BOOST_SERIALIZATION_NVP(func); diff --git a/FT/Espresso/Espresso/GLMCalibrationFunction.hh b/FT/Espresso/Espresso/GLMCalibrationFunction.hh index 39b931fd72ef945747b307fd400b959e30bfe5e3..0edb0205db5fe43f5cf5b0f9ccc4babd5455b9a6 100644 --- a/FT/Espresso/Espresso/GLMCalibrationFunction.hh +++ b/FT/Espresso/Espresso/GLMCalibrationFunction.hh @@ -88,7 +88,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(CalibrationFunction); //ar & boost::serialization::base_object<CalibrationFunction>(*this); ar & BOOST_SERIALIZATION_NVP(glm); diff --git a/FT/Espresso/Espresso/GLMModel.hh b/FT/Espresso/Espresso/GLMModel.hh index c1bf735a167a9aeacab29586edd721af0495a8df..5a5ee80be5fe28db99a5d7309a1c2e91f904bb36 100644 --- a/FT/Espresso/Espresso/GLMModel.hh +++ b/FT/Espresso/Espresso/GLMModel.hh @@ -110,7 +110,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) {} + void serialize(Archive&, const unsigned int) {} }; /** diff --git a/FT/Espresso/Espresso/GLMNSpline.hh b/FT/Espresso/Espresso/GLMNSpline.hh index 992427c0b7e9a47e90d0221ecab69deb5ae3cb7d..7786154e06877078605d60bd3278a4adc1a69a84 100644 --- a/FT/Espresso/Espresso/GLMNSpline.hh +++ b/FT/Espresso/Espresso/GLMNSpline.hh @@ -87,7 +87,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(GLMModel); //ar & boost::serialization::base_object<GLMModel>(*this); ar & BOOST_SERIALIZATION_NVP(nodes); @@ -107,13 +107,13 @@ namespace boost { namespace serialization { template<class Archive> - inline void save_construct_data(Archive& ar, const Espresso::GLMNSpline* v, const unsigned int version) { + inline void save_construct_data(Archive& ar, const Espresso::GLMNSpline* v, const unsigned int /* version */) { std::vector<double> nodes = v->GetNodes(); ar << BOOST_SERIALIZATION_NVP(nodes); } template<class Archive> - inline void load_construct_data(Archive& ar, Espresso::GLMNSpline* v, const unsigned int version) { + inline void load_construct_data(Archive& ar, Espresso::GLMNSpline* v, const unsigned int /* version */) { std::vector<double> nodes; ar >> BOOST_SERIALIZATION_NVP(nodes); ::new(v)Espresso::GLMNSpline(nodes); diff --git a/FT/Espresso/Espresso/GLMPolynomial.hh b/FT/Espresso/Espresso/GLMPolynomial.hh index 2df2e384ebca55c900d083856bde566617e4e1f0..ab0f6b22569c53ce01da652f22900596d02f3f11 100644 --- a/FT/Espresso/Espresso/GLMPolynomial.hh +++ b/FT/Espresso/Espresso/GLMPolynomial.hh @@ -73,7 +73,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(GLMModel); //ar & boost::serialization::base_object<GLMModel>(*this); ar & BOOST_SERIALIZATION_NVP(degree); @@ -91,13 +91,13 @@ namespace boost { namespace serialization { template<class Archive> - inline void save_construct_data(Archive& ar, const Espresso::GLMPolynomial* v, const unsigned int version) { + inline void save_construct_data(Archive& ar, const Espresso::GLMPolynomial* v, const unsigned int /* version */) { std::size_t degree = v->NumParams()-1; ar << boost::serialization::make_nvp("poly_construct_degree",degree); } template<class Archive> - inline void load_construct_data(Archive& ar, Espresso::GLMPolynomial* v, const unsigned int version) { + inline void load_construct_data(Archive& ar, Espresso::GLMPolynomial* v, const unsigned int /* version */) { unsigned int degree; ar >> boost::serialization::make_nvp("poly_construct_degree",degree); ::new(v)Espresso::GLMPolynomial(degree); diff --git a/FT/Espresso/Espresso/Matrix.hh b/FT/Espresso/Espresso/Matrix.hh index 52bec44e2f512208d6a62da5dc7ddcba8ad51630..1d19912613996e3ba7f7574be609bc6fe9d9cf1a 100644 --- a/FT/Espresso/Espresso/Matrix.hh +++ b/FT/Espresso/Espresso/Matrix.hh @@ -201,7 +201,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_NVP(n); ar & BOOST_SERIALIZATION_NVP(m); if (Archive::is_loading::value) v = reinterpret_cast<epm_gsl_matrix*>(gsl_matrix_calloc(n,m)); @@ -226,7 +226,7 @@ namespace boost { namespace serialization { template<class Archive> - inline void save_construct_data(Archive& ar, const Espresso::Matrix* v, const unsigned int version) { + inline void save_construct_data(Archive& ar, const Espresso::Matrix* v, const unsigned int /* version */) { std::size_t n = v->size1(); std::size_t m = v->size2(); ar << boost::serialization::make_nvp("matrix_construct_numrows",n); @@ -234,7 +234,7 @@ namespace boost { } template<class Archive> - inline void load_construct_data(Archive& ar, Espresso::Matrix* v, const unsigned int version) { + inline void load_construct_data(Archive& ar, Espresso::Matrix* v, const unsigned int /* version */) { std::size_t n,m; ar >> boost::serialization::make_nvp("matrix_construct_numrows",n); ar >> boost::serialization::make_nvp("matrix_construct_numcols",m); diff --git a/FT/Espresso/Espresso/TypicalCalibration.hh b/FT/Espresso/Espresso/TypicalCalibration.hh index 068fb536aa386585e59aba9ea5295db4938f99ef..6794c33f2d580aa3bed935f40795c6d186450f27 100644 --- a/FT/Espresso/Espresso/TypicalCalibration.hh +++ b/FT/Espresso/Espresso/TypicalCalibration.hh @@ -137,7 +137,7 @@ namespace Espresso private: friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_BASE_OBJECT_NVP(Calibration); //ar & boost::serialization::base_object<Calibration>(*this); ar & BOOST_SERIALIZATION_NVP(numParams); diff --git a/FT/Espresso/Espresso/Vector.hh b/FT/Espresso/Espresso/Vector.hh index cef3dc5b97e87a84f1558e531d3e8b3db2ea4237..e7f5a248225cfa6b1590394af1423735da7e712d 100644 --- a/FT/Espresso/Espresso/Vector.hh +++ b/FT/Espresso/Espresso/Vector.hh @@ -173,7 +173,7 @@ namespace Espresso { friend class boost::serialization::access; template<class Archive> - void serialize(Archive& ar, const unsigned int version) { + void serialize(Archive& ar, const unsigned int /* version */) { ar & BOOST_SERIALIZATION_NVP(n); if (Archive::is_loading::value) v = reinterpret_cast<epm_gsl_vector*>(gsl_vector_calloc(n)); ar & boost::serialization::make_nvp("vector_size",v->size); @@ -192,13 +192,13 @@ namespace boost { namespace serialization { template<class Archive> - inline void save_construct_data(Archive& ar, const Espresso::Vector* v, const unsigned int version) { + inline void save_construct_data(Archive& ar, const Espresso::Vector* v, const unsigned int /* version */) { std::size_t n = v->size(); ar << boost::serialization::make_nvp("vector_construct_size",n); } template<class Archive> - inline void load_construct_data(Archive& ar, Espresso::Vector* v, const unsigned int version) { + inline void load_construct_data(Archive& ar, Espresso::Vector* v, const unsigned int /* version */) { std::size_t n; ar >> boost::serialization::make_nvp("vector_construct_size",n); ::new(v)Espresso::Vector(n); diff --git a/PIDCalib/PIDPerfTools/src/MultiTrackCalibTool.cpp b/PIDCalib/PIDPerfTools/src/MultiTrackCalibTool.cpp index ae4cfc425f8c1c2c4918fa67e7c6d816827e9364..b7380e2b5fa3d6b0bf9b2545c6e4c59f23fc97e5 100644 --- a/PIDCalib/PIDPerfTools/src/MultiTrackCalibTool.cpp +++ b/PIDCalib/PIDPerfTools/src/MultiTrackCalibTool.cpp @@ -71,7 +71,7 @@ MultiTrackCalibTool::MultiTrackCalibTool(std::string Name, m_OutputTree = new TTree(TString(m_name+"_PIDCalibTree").Data(), "PID Calibration Results"); m_InputRefTree = RefTree; - if ( (m_InputRefTree==NULL) ) + if ( m_InputRefTree==NULL ) { cout << "ERROR: Failed to obtain pointer to TTree " << endl; @@ -90,7 +90,7 @@ MultiTrackCalibTool::MultiTrackCalibTool(std::string Name, void MultiTrackCalibTool::Write(std::string name = "") { if ( name.empty() ) name = m_name+"_PIDCalibTree"; - if ( (m_OutputTree==NULL) ) return; + if ( m_OutputTree==NULL ) return; if ( (m_OutputFile!=NULL) ) { m_OutputFile->cd(); m_OutputTree->Write(name.c_str()); @@ -140,7 +140,7 @@ void MultiTrackCalibTool::SetOutputFile(const std::string& FileName, const std:: } m_OutputFile = TFile::Open(FileName.c_str(), Mode.c_str()); - if ( (m_OutputFile==NULL) ) { + if ( m_OutputFile==NULL ) { cout << "ERROR: Failed to create output file. Check the file permissions." << " If opening in NEW/CREATE mode, ensure that the specified file does not exist" << endl; @@ -153,7 +153,7 @@ void MultiTrackCalibTool::SetOutputFile(const std::string& FileName, const std:: //============================================================================= Bool_t MultiTrackCalibTool::validBranch(TTree* tt, const TString& brName) { - if ( (tt==NULL) ) { + if ( tt==NULL ) { cout << "No TTree specified" << endl; return kFALSE; } diff --git a/PIDCalib/PIDPerfTools/src/PerfCalculator.icpp b/PIDCalib/PIDPerfTools/src/PerfCalculator.icpp index db0cc8f9b850224f2e709b36d41b2dc09dbd917d..115a7ef64ef500741d128526fbff1e299d5e9d70 100644 --- a/PIDCalib/PIDPerfTools/src/PerfCalculator.icpp +++ b/PIDCalib/PIDPerfTools/src/PerfCalculator.icpp @@ -397,12 +397,12 @@ TGraphAsymmErrors* PerfCalculator<T>::Perf_Scan( const std::list<std::string>& C DLLScan->GetXaxis()->SetTitle( ((Results.front().DLL)[index]).c_str() ); } - delete Effs; - delete Errsl; - delete Errsh; - delete DLL; - delete DLLl; - delete DLLh; + delete[] Effs; + delete[] Errsl; + delete[] Errsh; + delete[] DLL; + delete[] DLLl; + delete[] DLLh; return DLLScan; } @@ -500,12 +500,12 @@ TGraphAsymmErrors* PerfCalculator<T>::Perf_Scan( const PIDResult::Container & Ex Errsl_2, Errsh_2); - delete Effs_1; - delete Errsl_1; - delete Errsh_1; - delete Effs_2; - delete Errsl_2; - delete Errsh_2; + delete[] Effs_1; + delete[] Errsl_1; + delete[] Errsh_1; + delete[] Effs_2; + delete[] Errsl_2; + delete[] Errsh_2; return DLLScan; @@ -606,12 +606,12 @@ TGraphAsymmErrors* PerfCalculator<T>::Perf_Scan_ToFile( const PIDResult::Contain Errsl_2, Errsh_2); - delete Effs_1; - delete Errsl_1; - delete Errsh_1; - delete Effs_2; - delete Errsl_2; - delete Errsh_2; + delete[] Effs_1; + delete[] Errsl_1; + delete[] Errsh_1; + delete[] Effs_2; + delete[] Errsl_2; + delete[] Errsh_2; return DLLScan; diff --git a/PhysFit/B2DXFitters/B2DXFitters/HistPID2D.h b/PhysFit/B2DXFitters/B2DXFitters/HistPID2D.h index df1872a99d57e9ff39e5d9b68b364abeca563e6c..966815124e01600dd64b946db99bf511bc776a83 100644 --- a/PhysFit/B2DXFitters/B2DXFitters/HistPID2D.h +++ b/PhysFit/B2DXFitters/B2DXFitters/HistPID2D.h @@ -20,11 +20,12 @@ using namespace std; class HistPID2D : public TNamed{ public: - HistPID2D(){}; + HistPID2D(){} HistPID2D(const TString& name, const TString& title); HistPID2D(const TString& name, const TString& title, const TString& fileDir, const TString& FileName1, const TString& FileName2 = ""); HistPID2D(const HistPID2D& other); + HistPID2D& operator=(const HistPID2D& other); virtual TObject* clone() const { return new HistPID2D(*this); } friend std::ostream & operator<< (std::ostream &out, const HistPID2D &s); diff --git a/PhysFit/B2DXFitters/B2DXFitters/PIDCalibrationSample.h b/PhysFit/B2DXFitters/B2DXFitters/PIDCalibrationSample.h index f7df379de0f1e991248d2a980d032d62c876f41d..44d4c43ab98e01d7fb19dae5d839293c27fd1f56 100644 --- a/PhysFit/B2DXFitters/B2DXFitters/PIDCalibrationSample.h +++ b/PhysFit/B2DXFitters/B2DXFitters/PIDCalibrationSample.h @@ -35,6 +35,7 @@ class PIDCalibrationSample : public TNamed { PIDCalibrationSample(const TString& name, const TString& title); PIDCalibrationSample(const PIDCalibrationSample& other); + PIDCalibrationSample& operator=(const PIDCalibrationSample& other); virtual TObject* clone() const { return new PIDCalibrationSample(*this); } virtual ~PIDCalibrationSample(); diff --git a/PhysFit/B2DXFitters/B2DXFitters/QRDecomposition.h b/PhysFit/B2DXFitters/B2DXFitters/QRDecomposition.h index 29046110f9dd088a2d4caaaffb625053d17e28f3..8195b793137bb3f19fbd6e2dfc76b49e8a2be971 100644 --- a/PhysFit/B2DXFitters/B2DXFitters/QRDecomposition.h +++ b/PhysFit/B2DXFitters/B2DXFitters/QRDecomposition.h @@ -251,12 +251,12 @@ class QRDecomposition // apply pivoting std::vector<F> tmp; tmp.reserve(nn); - for (unsigned i = nn; i--; tmp[i] = b[pr[i] / nn]); + for (unsigned i = 0; i < nn; ++i) { tmp[i] = b[pr[i] / nn]; } // solve F* data = tmp.data(); doSolve(nn, data); // copy back to user supplied vector - for (unsigned i = nn; i--; b[pc[i]] = tmp[i]); + for (unsigned i = 0; i < nn; ++i) { b[pc[i]] = tmp[i]; } return nSing(); } diff --git a/PhysFit/B2DXFitters/src/Bs2Dsh2011TDAnaModels.cxx b/PhysFit/B2DXFitters/src/Bs2Dsh2011TDAnaModels.cxx index 4596b2f99a5c3dd7d203a8e65389cfafc0e12b62..4463a90294f3bea563fa05c3bc447b3114e8b2a6 100644 --- a/PhysFit/B2DXFitters/src/Bs2Dsh2011TDAnaModels.cxx +++ b/PhysFit/B2DXFitters/src/Bs2Dsh2011TDAnaModels.cxx @@ -90,7 +90,7 @@ namespace Bs2Dsh2011TDAnaModels { TString y = CheckDataYear(samplemode,debug); TString sam = CheckPolarity(samplemode,debug); TString mode = CheckDMode(samplemode, debug); - if ( mode == "" ) { mode == CheckKKPiMode(samplemode,debug);} + if ( mode == "" ) { mode = CheckKKPiMode(samplemode,debug);} RooRealVar lum; for (int i = 0; i<3; i++ ) diff --git a/PhysFit/B2DXFitters/src/Bs2DshDsHHHPi0Models.cxx b/PhysFit/B2DXFitters/src/Bs2DshDsHHHPi0Models.cxx index 95b0520293bac4041f2ee44065ea7d65bebe7ace..03a6458a03a5800c3c0cf965cd823c328549781d 100644 --- a/PhysFit/B2DXFitters/src/Bs2DshDsHHHPi0Models.cxx +++ b/PhysFit/B2DXFitters/src/Bs2DshDsHHHPi0Models.cxx @@ -48,7 +48,7 @@ namespace Bs2DshDsHHHPi0Models { if (debug == true) { cout<<"---------------------------------------------"<<endl; - cout<<"[ERROR] Model not supported. Please creat it "<<endl; + cout<<"[ERROR] Model not supported. Please create it"<<endl; cout<<"---------------------------------------------"<<endl; } @@ -56,8 +56,8 @@ namespace Bs2DshDsHHHPi0Models { if ( workInt != NULL ) {} if ( obs.size() <5 ) {} if ( types.size() <5 ) {} - if ( samplemode = "" ) {} - if ( merge = "") {} + if ( samplemode == "" ) {} + if ( merge == "") {} return NULL; } @@ -78,7 +78,7 @@ namespace Bs2DshDsHHHPi0Models { if (debug == true) { cout<<"---------------------------------------------"<<endl; - cout<<"[ERROR] Model not supported. Please creat it "<<endl; + cout<<"[ERROR] Model not supported. Please create it"<<endl; cout<<"---------------------------------------------"<<endl; } @@ -86,8 +86,8 @@ namespace Bs2DshDsHHHPi0Models { if ( workInt != NULL ) {} if ( obs.size()<5 ) {} if ( types.size() <5 ) {} - if ( samplemode = "" ) {} - if ( merge = "") {} + if ( samplemode == "" ) {} + if ( merge == "") {} return NULL; } diff --git a/PhysFit/B2DXFitters/src/HistPID2D.cxx b/PhysFit/B2DXFitters/src/HistPID2D.cxx index 4d1c76af0944940b0b916c1780c784b5f8d3d6f0..e7ca880d2e65955854017799dd72a234ed638836 100644 --- a/PhysFit/B2DXFitters/src/HistPID2D.cxx +++ b/PhysFit/B2DXFitters/src/HistPID2D.cxx @@ -260,7 +260,7 @@ HistPID2D::HistPID2D(const TString& name, const TString& title, const TString& f for(int j=0; j<numbinX; j++) { - for( int k = 0; j<numbinY; k++) + for( int k = 0; k<numbinY; k++) { Double_t bin1 = histA1->GetBinContent(j,k); Double_t bin2 = histA2->GetBinContent(j,k); @@ -300,7 +300,15 @@ HistPID2D::HistPID2D(const HistPID2D& other) : _fileName = other._fileName; _hist = other._hist; } +HistPID2D& HistPID2D::operator=(const HistPID2D& other) { + this->TNamed::operator=(other); + _polarity = other._polarity; + _fileName = other._fileName; + _hist = other._hist; + + return *this; +} std::pair <Double_t,Double_t> HistPID2D::GetValues(TString key1, TString key2, std::vector <TString> &basicName, std::vector <Double_t> &basicVal, diff --git a/PhysFit/B2DXFitters/src/MassFitUtils.cxx b/PhysFit/B2DXFitters/src/MassFitUtils.cxx index 13fd963ac4a67cd656933b327fb777ad51247c99..ca9f059044d5d73e51595c8e7a0972f24ac2b6c8 100644 --- a/PhysFit/B2DXFitters/src/MassFitUtils.cxx +++ b/PhysFit/B2DXFitters/src/MassFitUtils.cxx @@ -112,14 +112,12 @@ namespace MassFitUtils { TString tN, TString tB, Double_t &varD, Int_t &varI, Float_t &varF, Short_t &varS, SmartBool &varB, UInt_t &varUI, ULong64_t &varUL, - TString mode, Double_t shift) + TString /* mode */, Double_t shift) { RooRealVar* obsVar = (RooRealVar*)obs->find(tN.Data()); Double_t val = GetValue(tB, varD, varI, varF, varS, varB, varUI, varUL); Float_t c = 299792458.0; Float_t corr = c/1e9; - corr = corr; - mode = mode; if ( tN != "" ) { @@ -3134,8 +3132,8 @@ namespace MassFitUtils { TString& filesDirMD, TString& sigMD, TString mVar, TString mDVar, - TString tagVar, - TString tagOmegaVar, + TString /* tagVar */, + TString /* tagOmegaVar */, RooWorkspace* work, Bool_t mistag, PlotSettings* plotSet, @@ -3151,8 +3149,6 @@ namespace MassFitUtils { } if ( plotSet == NULL ) { plotSet = new PlotSettings("plotSet","plotSet"); } - tagVar = tagVar; - tagOmegaVar = tagOmegaVar; std::vector <MCBackground*> MCBkgMU; Int_t numBkgMU = CheckNumberOfBackgrounds(filesDirMU,sigMU, debug); diff --git a/PhysFit/B2DXFitters/src/PIDCalibrationSample.cxx b/PhysFit/B2DXFitters/src/PIDCalibrationSample.cxx index b1cdb31c3a7f4f42000e866bae72f968d68f7143..9b1d573447801647361321231229c835898dad13 100644 --- a/PhysFit/B2DXFitters/src/PIDCalibrationSample.cxx +++ b/PhysFit/B2DXFitters/src/PIDCalibrationSample.cxx @@ -73,6 +73,28 @@ PIDCalibrationSample::PIDCalibrationSample(const PIDCalibrationSample& other) : _var2Name = other._var2Name; } +PIDCalibrationSample& PIDCalibrationSample::operator=(const PIDCalibrationSample& other) { + this->TNamed::operator=(other); + + _fileName = other._fileName; + _workName = other._workName; + _dataName = other._dataName; + _file = other._file; + _work= other._work; + _data = other._data; + + _polarity = other._polarity; + _year = other._year; + _stripping = other._stripping; + _sample = other._sample; + _type = other._type; + _PIDName = other._PIDName; + _weightName = other._weightName; + _var1Name = other._var1Name; + _var2Name = other._var2Name; + + return *this; +} PIDCalibrationSample::~PIDCalibrationSample() { } diff --git a/PhysFit/P2VV/src/RooAbsGaussModelEfficiency.cxx b/PhysFit/P2VV/src/RooAbsGaussModelEfficiency.cxx index 841e31a1b32566b8f29dfab709d8cf8214c886e4..550ef2127483b40b051b281e5d6ccbf474ed4668 100644 --- a/PhysFit/P2VV/src/RooAbsGaussModelEfficiency.cxx +++ b/PhysFit/P2VV/src/RooAbsGaussModelEfficiency.cxx @@ -85,7 +85,7 @@ RooGaussModelAcceptance::M_n<MaxOrder>::M_n(double x, const std::complex<double> std::complex<double> RooGaussModelAcceptance::K_n::operator()(unsigned i) const { - assert(0<=i&&i<=3); + assert(i<=3); switch(i) { case 0 : return 0.5*_zi; case 1 : return 0.5*_zi*_zi; diff --git a/RootTools/SimpleTools/src/crop.cc b/RootTools/SimpleTools/src/crop.cc index 1fdd5848f413e547a8690a91520f7d3f78fb9c5c..977b7463d1b947e13605efdbfae60db518b1ef1e 100755 --- a/RootTools/SimpleTools/src/crop.cc +++ b/RootTools/SimpleTools/src/crop.cc @@ -904,9 +904,9 @@ void PlotSoRSBSteps(){ SoRSBStepsGraph->GetXaxis()->SetBinLabel(SoRSBStepsGraph->GetXaxis()->FindBin(i),StepNames[i-1]); } evoCanvas->Write(); - delete SoRSBStepArr; - delete dSoRSBStepArr; - delete StepArr; + delete[] SoRSBStepArr; + delete[] dSoRSBStepArr; + delete[] StepArr; SoRSBStepsGraph->Delete(); } void PlotRoC(UInt_t cut){