From 4ce766eb4226c070c454ba72807fbf481119a5cb Mon Sep 17 00:00:00 2001 From: hristov Date: Tue, 27 Jul 2010 09:27:40 +0000 Subject: [PATCH] Changes for bug #70680: AliROOT Coverity DELETE_ARRAY checker fix --- CORRFW/AliCFContainer.cxx | 2 +- EMCAL/AliEMCALSDigitizer.cxx | 2 +- EVE/EveDet/AliEveListAnalyserEditor.cxx | 2 +- EVE/EveDet/AliEveTRDTrackList.cxx | 2 +- EVE/EveDet/AliEveTRDTrackListEditor.cxx | 2 +- HLT/trigger/AliHLTD0toKpi.cxx | 2 +- HMPID/AliHMPIDReconHTA.cxx | 2 +- ITS/AliITS.cxx | 2 +- ITS/AliITSBeamTestDigSSD.cxx | 2 +- ITS/AliITSOnlineSPDfoAnalyzer.cxx | 10 ++-- ITS/AliITSgeomSSD.cxx | 8 ++-- JETAN/AliEventShape.cxx | 6 +-- JETAN/AliUA1JetFinderV2.cxx | 48 +++++++++---------- PHOS/AliPHOSAnalyze.cxx | 2 +- PWG1/TPC/AliTPCtaskPID.cxx | 2 +- PWG1/TPC/AliTPCtaskQA.cxx | 2 +- .../AliFemto/AliFemtoEventReaderAOD.cxx | 2 +- .../AliFemtoEventReaderESDChainKine.cxx | 2 +- .../AliAnalysisTaskChargedHadronSpectra.cxx | 2 +- PWG3/hfe/AliHFEcollection.cxx | 2 +- STAT/AliTMinuitToolkit.cxx | 4 +- STEER/AliVertexerTracks.cxx | 14 +++--- TOF/AliTOFGeometry.cxx | 2 +- TOF/AliTOFLvHvDataPoints.cxx | 2 +- TPC/AliTPCCalibCE.cxx | 6 +-- TPC/AliTPCCalibTCF.cxx | 4 +- TPC/AliTPCCalibViewer.cxx | 4 +- TPC/AliTPCCalibViewerGUItime.cxx | 2 +- TPC/AliTPCDigitizer.cxx | 4 +- TPC/AliTPCMonitor.cxx | 2 +- TPC/AliTPCcalibBase.cxx | 4 +- TPC/AliTPCcalibCosmic.cxx | 4 +- TPC/AliTPCcalibPID.cxx | 2 +- TPC/AliTPCcalibTimeGain.cxx | 4 +- TPC/AliTPCcalibV0.cxx | 2 +- TRD/AliTRDPreprocessor.cxx | 4 +- TTherminator/AliGenTherminator.cxx | 2 +- TUHKMgen/AliGenUHKM.cxx | 2 +- 38 files changed, 86 insertions(+), 86 deletions(-) diff --git a/CORRFW/AliCFContainer.cxx b/CORRFW/AliCFContainer.cxx index 9467c82d4d7..24144c736d9 100644 --- a/CORRFW/AliCFContainer.cxx +++ b/CORRFW/AliCFContainer.cxx @@ -463,7 +463,7 @@ void AliCFContainer::Print(const Option_t*) const { Double_t *binLimits = new Double_t[GetNBins(iVar)+1]; GetBinLimits(iVar,binLimits); AliInfo(Form("variable %d \t -> %s : %d bins in [%f,%f]",iVar,GetVarTitle(iVar),GetNBins(iVar),binLimits[0],binLimits[GetNBins(iVar)])); - delete binLimits; + delete[] binLimits; } AliInfo("===================================================================================="); } diff --git a/EMCAL/AliEMCALSDigitizer.cxx b/EMCAL/AliEMCALSDigitizer.cxx index 09b9d359748..24de52b9e2f 100644 --- a/EMCAL/AliEMCALSDigitizer.cxx +++ b/EMCAL/AliEMCALSDigitizer.cxx @@ -465,7 +465,7 @@ void AliEMCALSDigitizer::PrintSDigits(Option_t * option) printf("%s",tempo); } } - delete tempo ; + delete [] tempo ; printf("\n** Sum %2.3f : %10.3f GeV/c **\n ", isum, Calibrate(isum)); } else printf("\n"); } diff --git a/EVE/EveDet/AliEveListAnalyserEditor.cxx b/EVE/EveDet/AliEveListAnalyserEditor.cxx index 15494f2d055..f9d2602cdd1 100644 --- a/EVE/EveDet/AliEveListAnalyserEditor.cxx +++ b/EVE/EveDet/AliEveListAnalyserEditor.cxx @@ -771,7 +771,7 @@ void AliEveListAnalyserEditor::HandleMacroPathSet() fteField->SetText(pathname); AddMacro(name); - if (name != 0) delete name; + if (name != 0) delete [] name; name = 0; } // Different path diff --git a/EVE/EveDet/AliEveTRDTrackList.cxx b/EVE/EveDet/AliEveTRDTrackList.cxx index 6a3d4e940db..612ee3cf2d5 100644 --- a/EVE/EveDet/AliEveTRDTrackList.cxx +++ b/EVE/EveDet/AliEveTRDTrackList.cxx @@ -594,7 +594,7 @@ Bool_t AliEveTRDTrackList::ApplyProcessMacros(const TList* selIterator, const TL if (procCmds != 0) delete [] procCmds; procCmds = 0; - if (mProcType != 0) delete mProcType; + if (mProcType != 0) delete [] mProcType; mProcType = 0; if (selCmds != 0) delete [] selCmds; diff --git a/EVE/EveDet/AliEveTRDTrackListEditor.cxx b/EVE/EveDet/AliEveTRDTrackListEditor.cxx index 9b01fd2611a..18702fde2ea 100644 --- a/EVE/EveDet/AliEveTRDTrackListEditor.cxx +++ b/EVE/EveDet/AliEveTRDTrackListEditor.cxx @@ -685,7 +685,7 @@ void AliEveTRDTrackListEditor::HandleMacroPathSet() fteField->SetText(pathname); AddMacro(name); - if (name != 0) delete name; + if (name != 0) delete [] name; name = 0; } // Different path diff --git a/HLT/trigger/AliHLTD0toKpi.cxx b/HLT/trigger/AliHLTD0toKpi.cxx index 05be6bcae4c..ecc9cbdbb22 100644 --- a/HLT/trigger/AliHLTD0toKpi.cxx +++ b/HLT/trigger/AliHLTD0toKpi.cxx @@ -96,7 +96,7 @@ AliAODVertex* AliHLTD0toKpi::ReconstructSecondaryVertex(TObjArray *trkArray, Dou id[0]=(UShort_t) t1->GetID(); id[1]=(UShort_t) t2->GetID(); vertexESD = (AliESDVertex*)vertexer->VertexForSelectedTracks(trkArray,id); - delete id; + delete [] id; delete vertexer; vertexer=NULL; if(!vertexESD) return vertexAOD; diff --git a/HMPID/AliHMPIDReconHTA.cxx b/HMPID/AliHMPIDReconHTA.cxx index 9b0e223bac2..949dd779e08 100644 --- a/HMPID/AliHMPIDReconHTA.cxx +++ b/HMPID/AliHMPIDReconHTA.cxx @@ -860,7 +860,7 @@ Bool_t AliHMPIDReconHTA::UniformDistrib() chi2+= (iPhiBin[i] - theo)*(iPhiBin[i] - theo)/theo; } - delete iPhiBin; + delete [] iPhiBin; Double_t prob = TMath::Prob(chi2, nPhiBins-1); AliDebug(1,Form(" Probability for uniform distrib: %6f.3 %s",prob,(prob<0.05) ? "rejected" : "accepted")); diff --git a/ITS/AliITS.cxx b/ITS/AliITS.cxx index 09d5d609aa0..bf25ca02e67 100644 --- a/ITS/AliITS.cxx +++ b/ITS/AliITS.cxx @@ -231,7 +231,7 @@ AliITS::~AliITS(){ delete[] fIdSens; Int_t size = 0; if (fDetTypeSim){ - size = GetITSgeom()->GetIndexMax(); + if (GetITSgeom()) size = GetITSgeom()->GetIndexMax(); delete fDetTypeSim; fDetTypeSim = 0; } diff --git a/ITS/AliITSBeamTestDigSSD.cxx b/ITS/AliITSBeamTestDigSSD.cxx index 35b6e485ba5..52c83a17477 100644 --- a/ITS/AliITSBeamTestDigSSD.cxx +++ b/ITS/AliITSBeamTestDigSSD.cxx @@ -116,7 +116,7 @@ void AliITSBeamTestDigSSD::Exec(Option_t* /*opt*/) { } delete [] newdigits; - delete idig; + delete [] idig; } diff --git a/ITS/AliITSOnlineSPDfoAnalyzer.cxx b/ITS/AliITSOnlineSPDfoAnalyzer.cxx index 3bb42c7c5b9..7582bea1238 100644 --- a/ITS/AliITSOnlineSPDfoAnalyzer.cxx +++ b/ITS/AliITSOnlineSPDfoAnalyzer.cxx @@ -441,7 +441,7 @@ Bool_t AliITSOnlineSPDfoAnalyzer::IsExisting(TArrayI dacs,Int_t hs, Int_t chip) for(Int_t i=0; iGetBin(entry,kFALSE); // kFALSE does not allocate another bin if(checkbin > -1) isOk = kTRUE; - delete entry; + delete [] entry; return isOk; } //----------------------------------------------------------- @@ -490,10 +490,10 @@ TArrayI AliITSOnlineSPDfoAnalyzer::GetCentralDACS(Int_t qualityflag, Int_t hs, I dacs.AddAt(qualityflag,fNdims); - delete mean; - delete goodbins; - delete bins; - delete val; + delete [] mean; + delete [] goodbins; + delete [] bins; + delete [] val; return dacs; } //------------------------------------------------------- diff --git a/ITS/AliITSgeomSSD.cxx b/ITS/AliITSgeomSSD.cxx index e61cb495506..026f5fa6e20 100644 --- a/ITS/AliITSgeomSSD.cxx +++ b/ITS/AliITSgeomSSD.cxx @@ -289,8 +289,8 @@ AliITSgeomSSD175::AliITSgeomSSD175() : AliITSgeomSSD(){ leC[kNstrips] = -kDxyz[0]; AliITSgeomSSD::ResetSSD(kDxyz,kangle,-kangle, kNstrips+1,leA,kNstrips+1,leC); - delete leA; - delete leC; + delete [] leA; + delete [] leC; } //________________________________________________________________________ ostream &operator<<(ostream &os,AliITSgeomSSD175 &p){ @@ -444,8 +444,8 @@ AliITSgeomSSD75and275::AliITSgeomSSD75and275(Int_t npar,Float_t *par) : leC[kNstrips] = -kDxyz[0]; AliITSgeomSSD::ResetSSD(par,kangleA,kangleC, kNstrips+1,leA,kNstrips+1,leC); - delete leA; - delete leC; + delete [] leA; + delete [] leC; } //________________________________________________________________________ ostream &operator<<(ostream &os,AliITSgeomSSD75and275 &p){ diff --git a/JETAN/AliEventShape.cxx b/JETAN/AliEventShape.cxx index 8c8712d4bd1..09485dd6e1f 100644 --- a/JETAN/AliEventShape.cxx +++ b/JETAN/AliEventShape.cxx @@ -186,9 +186,9 @@ TArrayD * AliEventShape::GetThrustParamMC(AliMCEvent* mcEvent, Int_t nstudymin, delete evsh; - delete ptT; - delete pxT; - delete pyT; + delete [] ptT; + delete [] pxT; + delete [] pyT; return evsh; } diff --git a/JETAN/AliUA1JetFinderV2.cxx b/JETAN/AliUA1JetFinderV2.cxx index 16d3f9b819e..913cf7bdd6e 100644 --- a/JETAN/AliUA1JetFinderV2.cxx +++ b/JETAN/AliUA1JetFinderV2.cxx @@ -279,13 +279,13 @@ void AliUA1JetFinderV2::FindJetsC() delete[] ncells; delete[] mult; //--- Added for jet reordering - delete etaJetOk; - delete phiJetOk; - delete etJetOk; - delete etsigJetOk; - delete etallJetOk; - delete ncellsJetOk; - delete multJetOk; + delete [] etaJetOk; + delete [] phiJetOk; + delete [] etJetOk; + delete [] etsigJetOk; + delete [] etallJetOk; + delete [] ncellsJetOk; + delete [] multJetOk; //-------------------------- } @@ -713,21 +713,21 @@ void AliUA1JetFinderV2::FindJets() delete etaCell2; delete phiCell2; delete flagCell2; - delete etaJet; - delete phiJet; - delete etJet; - delete etsigJet; - delete etallJet; - delete ncellsJet; - delete multJet; + delete [] etaJet; + delete [] phiJet; + delete [] etJet; + delete [] etsigJet; + delete [] etallJet; + delete [] ncellsJet; + delete [] multJet; //--- Added for jet reordering - delete etaJetOk; - delete phiJetOk; - delete etJetOk; - delete etsigJetOk; - delete etallJetOk; - delete ncellsJetOk; - delete multJetOk; + delete [] etaJetOk; + delete [] phiJetOk; + delete [] etJetOk; + delete [] etsigJetOk; + delete [] etallJetOk; + delete [] ncellsJetOk; + delete [] multJetOk; //-------------------------- delete trackinjet; delete idxjets; @@ -930,7 +930,7 @@ void AliUA1JetFinderV2::RunAlgoritm(Int_t nIn, Float_t* etCell, Float_t* const e } //delete - delete index; + delete[] index; } @@ -1134,8 +1134,8 @@ void AliUA1JetFinderV2::RunAlgoritmC(Float_t etbgTotal, Double_t dEtTotal, Int_t } //delete - delete index; - delete idx; + delete [] index; + delete [] idx; } diff --git a/PHOS/AliPHOSAnalyze.cxx b/PHOS/AliPHOSAnalyze.cxx index 100d5119cb3..51384cabe95 100644 --- a/PHOS/AliPHOSAnalyze.cxx +++ b/PHOS/AliPHOSAnalyze.cxx @@ -636,7 +636,7 @@ void AliPHOSAnalyze::Ls(){ mfile->Write(); mfile->Close(); delete mfile ; - delete nRecParticles; + delete [] nRecParticles; } diff --git a/PWG1/TPC/AliTPCtaskPID.cxx b/PWG1/TPC/AliTPCtaskPID.cxx index 3e6f5739fef..fd3080d5ec3 100644 --- a/PWG1/TPC/AliTPCtaskPID.cxx +++ b/PWG1/TPC/AliTPCtaskPID.cxx @@ -406,5 +406,5 @@ void AliTPCtaskPID::BinLogX(TAxis *axis) { new_bins[i] = factor * new_bins[i-1]; } axis->Set(bins, new_bins); - delete new_bins; + delete [] new_bins; } diff --git a/PWG1/TPC/AliTPCtaskQA.cxx b/PWG1/TPC/AliTPCtaskQA.cxx index b4e5d0c64e3..038d295e48c 100644 --- a/PWG1/TPC/AliTPCtaskQA.cxx +++ b/PWG1/TPC/AliTPCtaskQA.cxx @@ -331,7 +331,7 @@ void AliTPCtaskQA::BinLogX(TAxis *axis) { new_bins[i] = factor * new_bins[i-1]; } axis->Set(bins, new_bins); - delete new_bins; + delete [] new_bins; } diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx index 808ae0828de..2a812314a46 100644 --- a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx +++ b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx @@ -520,7 +520,7 @@ void AliFemtoEventReaderAOD::CopyAODtoFemtoEvent(AliFemtoEvent *tEvent) tEvent->SetNumberOfTracks(realnofTracks);//setting number of track which we read in event - if (mcP) delete motherids; + if (mcP) delete [] motherids; cout<<"end of reading nt "<SetNumberOfTracks(realnofTracks);//setting number of track which we read in event fCurEvent++; diff --git a/PWG2/SPECTRA/AliAnalysisTaskChargedHadronSpectra.cxx b/PWG2/SPECTRA/AliAnalysisTaskChargedHadronSpectra.cxx index 16ee981893d..e8c0df1dac2 100644 --- a/PWG2/SPECTRA/AliAnalysisTaskChargedHadronSpectra.cxx +++ b/PWG2/SPECTRA/AliAnalysisTaskChargedHadronSpectra.cxx @@ -686,7 +686,7 @@ void AliAnalysisTaskChargedHadronSpectra::BinLogX(const TH1 *h) { newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete [] newBins; } diff --git a/PWG3/hfe/AliHFEcollection.cxx b/PWG3/hfe/AliHFEcollection.cxx index bc33ad0cdee..012cce65df8 100644 --- a/PWG3/hfe/AliHFEcollection.cxx +++ b/PWG3/hfe/AliHFEcollection.cxx @@ -469,7 +469,7 @@ Bool_t AliHFEcollection::BinLogAxis(const char* name, Int_t dim){ newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete [] newBins; return kTRUE; diff --git a/STAT/AliTMinuitToolkit.cxx b/STAT/AliTMinuitToolkit.cxx index 6feb61882aa..d79a24eb87d 100644 --- a/STAT/AliTMinuitToolkit.cxx +++ b/STAT/AliTMinuitToolkit.cxx @@ -385,8 +385,8 @@ void AliTMinuitToolkit::Fit() { if (fMaxCalls != 500 || fPrecision != 1) minuit->ExecuteCommand(fFitAlgorithm, argList, 2); fUseRobust = true; - delete sortList; - delete indexList; + delete [] sortList; + delete [] indexList; } // fill parameter vector diff --git a/STEER/AliVertexerTracks.cxx b/STEER/AliVertexerTracks.cxx index 5dd33ab3217..b8cf3d783da 100644 --- a/STEER/AliVertexerTracks.cxx +++ b/STEER/AliVertexerTracks.cxx @@ -212,7 +212,7 @@ AliESDVertex* AliVertexerTracks::FindPrimaryVertex(const AliVEvent *vEvent) FindPrimaryVertex(&trkArrayOrig,idOrig); if(fMode==0) trkArrayOrig.Delete(); - delete idOrig; idOrig=NULL; + delete[] idOrig; idOrig=NULL; if(f) { f->Close(); delete f; f = NULL; @@ -265,7 +265,7 @@ AliESDVertex* AliVertexerTracks::FindPrimaryVertex(const TObjArray *trkArrayOrig // fill fTrkArraySel, for VertexFinder() fIdSel = new UShort_t[nTrksOrig]; PrepareTracks(*trkArrayOrig,idOrig,0); - if(fIdSel) { delete fIdSel; fIdSel=NULL; } + if(fIdSel) { delete[] fIdSel; fIdSel=NULL; } Double_t cutsave = fDCAcut; fDCAcut = fDCAcutIter0; // vertex finder @@ -832,7 +832,7 @@ AliESDVertex* AliVertexerTracks::RemoveTracksFromVertex(AliESDVertex *inVtx, } } outVtx->SetIndices(nIndices,outindices); - if (outindices) delete outindices; + if (outindices) delete [] outindices; /* printf("Vertex before removing tracks:"); @@ -1203,8 +1203,8 @@ AliESDVertex AliVertexerTracks::TrackletVertexFinder(AliStrLine **lines, const I } AliESDVertex theVert(initPos,covmatrix,99999.,knacc); theVert.SetDispersion(sigma); - delete vectP0; - delete vectP1; + delete [] vectP0; + delete [] vectP1; return theVert; } @@ -1706,7 +1706,7 @@ AliESDVertex* AliVertexerTracks::VertexForSelectedTracks(const TObjArray *trkArr } // clean up - if (indices) {delete indices; indices=NULL;} + if (indices) {delete [] indices; indices=NULL;} delete fIdSel; fIdSel=NULL; fTrkArraySel.Delete(); @@ -1734,7 +1734,7 @@ AliESDVertex* AliVertexerTracks::VertexForSelectedESDTracks(TObjArray *trkArray, VertexForSelectedTracks(trkArray,id,optUseFitter,optPropagate,optUseDiamondConstraint); - delete id; id=NULL; + delete [] id; id=NULL; return fCurrentVertex; } diff --git a/TOF/AliTOFGeometry.cxx b/TOF/AliTOFGeometry.cxx index 308cb675476..e558af41aa1 100644 --- a/TOF/AliTOFGeometry.cxx +++ b/TOF/AliTOFGeometry.cxx @@ -1445,7 +1445,7 @@ void AliTOFGeometry::DetToSectorRF(Int_t vol[5], Double_t **coord) for (Int_t jj=0; jj<4; jj++) padToSector.MasterToLocal(&cornerPad[jj][0], &coord[jj][0]); - delete cornerPad; + delete [] cornerPad; //sectorToPad.LocalToMaster(cornerPad, coord); diff --git a/TOF/AliTOFLvHvDataPoints.cxx b/TOF/AliTOFLvHvDataPoints.cxx index bc30579fc36..507749d4b77 100644 --- a/TOF/AliTOFLvHvDataPoints.cxx +++ b/TOF/AliTOFLvHvDataPoints.cxx @@ -302,7 +302,7 @@ Bool_t AliTOFLvHvDataPoints::MergeMaps() { } - delete controller; + delete [] controller; for (Int_t ii=0; iiGetTime() = %d ",ii,fMap[ii]->GetTime())); diff --git a/TPC/AliTPCCalibCE.cxx b/TPC/AliTPCCalibCE.cxx index 3b644b25150..838afcd005f 100644 --- a/TPC/AliTPCCalibCE.cxx +++ b/TPC/AliTPCCalibCE.cxx @@ -1727,9 +1727,9 @@ TGraph *AliTPCCalibCE::MakeGraphTimeCE(Int_t sector, Int_t xVariable, Int_t fitT if ( xVariable == 2 ) delete xVar; - delete x; - delete y; - delete sortIndex; + delete [] x; + delete [] y; + delete [] sortIndex; return gr; } //_____________________________________________________________________ diff --git a/TPC/AliTPCCalibTCF.cxx b/TPC/AliTPCCalibTCF.cxx index 5511e7ef986..d421a7b93d8 100644 --- a/TPC/AliTPCCalibTCF.cxx +++ b/TPC/AliTPCCalibTCF.cxx @@ -1626,8 +1626,8 @@ TNtuple *AliTPCCalibTCF::ApplyTCFilter(TH1F *hisIn, Double_t *coefZ, Double_t *c signalIn->~Double_t(); signalOut->~Double_t(); - delete signalIn; - delete signalOut; + delete [] signalIn; + delete [] signalOut; return pulseTuple; diff --git a/TPC/AliTPCCalibViewer.cxx b/TPC/AliTPCCalibViewer.cxx index 13e5dfd4a6a..c092ab6e3b4 100644 --- a/TPC/AliTPCCalibViewer.cxx +++ b/TPC/AliTPCCalibViewer.cxx @@ -305,8 +305,8 @@ const char* AliTPCCalibViewer::AddAbbreviations(const Char_t *c, Bool_t printDra str.ReplaceAll(removeString, ""); if (printDrawCommand) std::cout << "The string looks now like: " << str.Data() << std::endl; - delete varSort; - delete normSort; + delete [] varSort; + delete [] normSort; return str.Data(); } diff --git a/TPC/AliTPCCalibViewerGUItime.cxx b/TPC/AliTPCCalibViewerGUItime.cxx index 8314d4ecd4f..5583ddfb70f 100644 --- a/TPC/AliTPCCalibViewerGUItime.cxx +++ b/TPC/AliTPCCalibViewerGUItime.cxx @@ -964,7 +964,7 @@ void AliTPCCalibViewerGUItime::DoDumpRuns() if (run!=prevRun) std::cout << Form("%d",run) << std::endl; prevRun=run; } - delete sortIndex; + delete [] sortIndex; } //______________________________________________________________________________ void AliTPCCalibViewerGUItime::DoParLimitChange() diff --git a/TPC/AliTPCDigitizer.cxx b/TPC/AliTPCDigitizer.cxx index b8c4677dcb3..ed62f3033bc 100644 --- a/TPC/AliTPCDigitizer.cxx +++ b/TPC/AliTPCDigitizer.cxx @@ -535,6 +535,6 @@ void AliTPCDigitizer::ExecSave(Option_t* option) delete digrow; for (Int_t i1=0;i1Draw(); ctrans2->Update(); delete four; - delete data; + delete [] data; } //__________________________________________________________________ diff --git a/TPC/AliTPCcalibBase.cxx b/TPC/AliTPCcalibBase.cxx index 79fffbb2f8b..aff72e6f944 100644 --- a/TPC/AliTPCcalibBase.cxx +++ b/TPC/AliTPCcalibBase.cxx @@ -383,7 +383,7 @@ void AliTPCcalibBase::BinLogX(THnSparse *h, Int_t axisDim) { new_bins[i] = factor * new_bins[i-1]; } axis->Set(bins, new_bins); - delete new_bins; + delete [] new_bins; } void AliTPCcalibBase::BinLogX(TH1 *h) { @@ -404,6 +404,6 @@ void AliTPCcalibBase::BinLogX(TH1 *h) { new_bins[i] = factor * new_bins[i-1]; } axis->Set(bins, new_bins); - delete new_bins; + delete [] new_bins; } diff --git a/TPC/AliTPCcalibCosmic.cxx b/TPC/AliTPCcalibCosmic.cxx index 3aaa6dd5d62..aea04cfe3d0 100644 --- a/TPC/AliTPCcalibCosmic.cxx +++ b/TPC/AliTPCcalibCosmic.cxx @@ -884,7 +884,7 @@ void AliTPCcalibCosmic::BinLogX(THnSparse *const h, Int_t axisDim) { newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete [] newBins; } @@ -907,7 +907,7 @@ void AliTPCcalibCosmic::BinLogX(TH1 *const h) { newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete [] newBins; } diff --git a/TPC/AliTPCcalibPID.cxx b/TPC/AliTPCcalibPID.cxx index bdf45b925db..ff2978114c2 100644 --- a/TPC/AliTPCcalibPID.cxx +++ b/TPC/AliTPCcalibPID.cxx @@ -499,7 +499,7 @@ void AliTPCcalibPID::BinLogX(THnSparse *h, Int_t axisDim) { newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete [] newBins; } diff --git a/TPC/AliTPCcalibTimeGain.cxx b/TPC/AliTPCcalibTimeGain.cxx index 2a80899fdb8..11093d43b9c 100644 --- a/TPC/AliTPCcalibTimeGain.cxx +++ b/TPC/AliTPCcalibTimeGain.cxx @@ -583,7 +583,7 @@ void AliTPCcalibTimeGain::BinLogX(THnSparse *h, Int_t axisDim) { newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete[] newBins; } @@ -606,7 +606,7 @@ void AliTPCcalibTimeGain::BinLogX(TH1 *h) { newBins[i] = factor * newBins[i-1]; } axis->Set(bins, newBins); - delete newBins; + delete[] newBins; } diff --git a/TPC/AliTPCcalibV0.cxx b/TPC/AliTPCcalibV0.cxx index 38406571aa3..96c0ca4f9c5 100644 --- a/TPC/AliTPCcalibV0.cxx +++ b/TPC/AliTPCcalibV0.cxx @@ -778,7 +778,7 @@ void AliTPCcalibV0::BinLogX(TH2F *h) { new_bins[i] = factor * new_bins[i-1]; } axis->Set(bins, new_bins); - delete new_bins; + delete [] new_bins; } diff --git a/TRD/AliTRDPreprocessor.cxx b/TRD/AliTRDPreprocessor.cxx index be94fadf1fa..8170ffe04b1 100644 --- a/TRD/AliTRDPreprocessor.cxx +++ b/TRD/AliTRDPreprocessor.cxx @@ -303,8 +303,8 @@ Bool_t AliTRDPreprocessor::ProcessDCS(TMap *dcsAliasMap) } Log ("*********** End of DCS **********"); - delete results; - delete nGraph; + delete [] results; + delete [] nGraph; return error; diff --git a/TTherminator/AliGenTherminator.cxx b/TTherminator/AliGenTherminator.cxx index b75b248a115..987a1dd19a4 100644 --- a/TTherminator/AliGenTherminator.cxx +++ b/TTherminator/AliGenTherminator.cxx @@ -296,7 +296,7 @@ void AliGenTherminator::Generate() AddHeader(header); fCollisionGeometry = (AliGenHijingEventHeader*) header; - delete idsOnStack; + delete [] idsOnStack; // gAlice->SetGenEventHeader(header); } diff --git a/TUHKMgen/AliGenUHKM.cxx b/TUHKMgen/AliGenUHKM.cxx index e5c829a4348..34bbdf8d373 100755 --- a/TUHKMgen/AliGenUHKM.cxx +++ b/TUHKMgen/AliGenUHKM.cxx @@ -467,7 +467,7 @@ void AliGenUHKM::Generate() AddHeader(header); fCollisionGeometry = (AliGenHijingEventHeader*) header; - delete idsOnStack; + delete [] idsOnStack; } -- 2.39.3